mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-05 19:41:42 +08:00
test: migrate test runner to vitest (#12206)
This commit is contained in:
parent
633e48a645
commit
694daef6ea
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
@ -48,7 +48,7 @@ jobs:
|
||||
run: pnpm install
|
||||
|
||||
- name: Run test cases
|
||||
run: npm test
|
||||
run: pnpm run test:coverage
|
||||
|
||||
- name: Upload coverage to Codecov
|
||||
uses: codecov/codecov-action@v1
|
||||
|
@ -7,6 +7,7 @@
|
||||
"test": "pnpm --dir ./packages/vant test",
|
||||
"test:watch": "pnpm --dir ./packages/vant test:watch",
|
||||
"test:update": "pnpm --dir ./packages/vant test:update",
|
||||
"test:coverage": "pnpm --dir ./packages/vant test:coverage",
|
||||
"build": "pnpm --dir ./packages/vant build",
|
||||
"build:site": "pnpm --dir ./packages/vant build:site"
|
||||
},
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
## Unreleased
|
||||
|
||||
- 移除 vant-cli test 命令
|
||||
- 移除 vant-cli release 命令
|
||||
- 移除 vant-cli changelog 命令
|
||||
- 升级 commander v11
|
||||
|
@ -1,51 +0,0 @@
|
||||
const { join } = require('path');
|
||||
const { existsSync } = require('fs');
|
||||
const { ROOT } = require('./shared.cjs');
|
||||
|
||||
const JEST_SETUP_FILE = join(__dirname, 'jest.setup.cjs');
|
||||
const JEST_FILE_MOCK_FILE = join(__dirname, 'jest.file-mock.cjs');
|
||||
const JEST_STYLE_MOCK_FILE = join(__dirname, 'jest.style-mock.cjs');
|
||||
|
||||
const DEFAULT_CONFIG = {
|
||||
testEnvironment: 'jsdom',
|
||||
moduleNameMapper: {
|
||||
'\\.(css|less|scss)$': JEST_STYLE_MOCK_FILE,
|
||||
'\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$':
|
||||
JEST_FILE_MOCK_FILE,
|
||||
},
|
||||
setupFilesAfterEnv: [JEST_SETUP_FILE],
|
||||
moduleFileExtensions: ['js', 'jsx', 'vue', 'ts', 'tsx'],
|
||||
transform: {
|
||||
'\\.(js|jsx|ts|tsx|vue)$':
|
||||
'<rootDir>/node_modules/@vant/cli/cjs/jest.transformer.cjs',
|
||||
},
|
||||
transformIgnorePatterns: ['/node_modules/(?!(@vant/cli))/'],
|
||||
snapshotSerializers: ['jest-serializer-html'],
|
||||
collectCoverage: true,
|
||||
collectCoverageFrom: [
|
||||
'src/**/*.{js,jsx,ts,tsx,vue}',
|
||||
'!**/demo/**',
|
||||
'!**/test/**',
|
||||
],
|
||||
coverageReporters: ['html', 'lcov', 'text-summary'],
|
||||
coverageDirectory: './test/coverage',
|
||||
testEnvironmentOptions: {
|
||||
// https://stackoverflow.com/questions/72428323/jest-referenceerror-vue-is-not-defined
|
||||
customExportConditions: ['node', 'node-addons'],
|
||||
},
|
||||
};
|
||||
|
||||
function readRootConfig() {
|
||||
const ROOT_CONFIG_PATH = join(ROOT, 'jest.config.js');
|
||||
|
||||
if (existsSync(ROOT_CONFIG_PATH)) {
|
||||
return require(ROOT_CONFIG_PATH);
|
||||
}
|
||||
|
||||
return {};
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
...DEFAULT_CONFIG,
|
||||
...readRootConfig(),
|
||||
};
|
@ -1 +0,0 @@
|
||||
module.exports = 'test-file-stub';
|
@ -1 +0,0 @@
|
||||
require('jest-canvas-mock');
|
@ -1 +0,0 @@
|
||||
module.exports = {};
|
@ -1,94 +0,0 @@
|
||||
const sfc = require('vue/compiler-sfc');
|
||||
const babel = require('@babel/core');
|
||||
const esbuild = require('esbuild');
|
||||
const nodePath = require('path');
|
||||
|
||||
const isJsxFile = (path) => /\.(j|t)sx$/.test(path);
|
||||
const isTsxFile = (path) => /\.tsx$/.test(path);
|
||||
const isVueFile = (path) => /\.vue$/.test(path);
|
||||
|
||||
const transformJsx = (code, path) => {
|
||||
const babelResult = babel.transformSync(code, {
|
||||
filename: path,
|
||||
babelrc: false,
|
||||
presets: isTsxFile(path) ? ['@babel/preset-typescript'] : [],
|
||||
plugins: [['@vue/babel-plugin-jsx']],
|
||||
});
|
||||
return babelResult?.code || '';
|
||||
};
|
||||
|
||||
const transformSFC = (code, path) => {
|
||||
const parsedPath = nodePath.parse(path);
|
||||
const { descriptor, errors } = sfc.parse(code, {
|
||||
filename: parsedPath.base,
|
||||
sourceRoot: parsedPath.dir,
|
||||
});
|
||||
|
||||
if (errors.length) {
|
||||
errors.forEach((error) => console.error(error));
|
||||
return '';
|
||||
}
|
||||
|
||||
const output = [];
|
||||
let bindingMetadata = {};
|
||||
|
||||
if (descriptor.script) {
|
||||
const content = descriptor.script.content.replace(
|
||||
'export default',
|
||||
'const script =',
|
||||
);
|
||||
output.push(content);
|
||||
} else if (descriptor.scriptSetup) {
|
||||
const result = sfc.compileScript(descriptor, {
|
||||
id: 'mock',
|
||||
});
|
||||
|
||||
const content = result.content.replace('export default', 'const script =');
|
||||
output.push(content);
|
||||
|
||||
if (result.bindings) {
|
||||
bindingMetadata = result.bindings;
|
||||
}
|
||||
} else {
|
||||
output.push(`const script = {};`);
|
||||
}
|
||||
|
||||
if (descriptor.template) {
|
||||
const render = sfc.compileTemplate({
|
||||
id: 'mock',
|
||||
source: descriptor.template.content,
|
||||
filename: path,
|
||||
compilerOptions: {
|
||||
bindingMetadata,
|
||||
},
|
||||
}).code;
|
||||
output.push(render);
|
||||
output.push('script.render = render;');
|
||||
}
|
||||
|
||||
output.push('export default script;');
|
||||
|
||||
return output.join('\n');
|
||||
};
|
||||
|
||||
const transformScript = (code) =>
|
||||
esbuild.transformSync(code, {
|
||||
target: 'es2016',
|
||||
format: 'cjs',
|
||||
loader: 'ts',
|
||||
}).code;
|
||||
|
||||
module.exports = {
|
||||
canInstrument: true,
|
||||
process(code, path) {
|
||||
if (isVueFile(path)) {
|
||||
code = transformSFC(code, path);
|
||||
}
|
||||
if (isJsxFile(path)) {
|
||||
code = transformJsx(code, path);
|
||||
}
|
||||
return {
|
||||
code: transformScript(code),
|
||||
};
|
||||
},
|
||||
};
|
@ -38,7 +38,6 @@
|
||||
"author": "chenjiahan",
|
||||
"license": "MIT",
|
||||
"devDependencies": {
|
||||
"@jest/types": "^29.1.2",
|
||||
"@types/fs-extra": "^11.0.1",
|
||||
"@types/less": "^3.0.3",
|
||||
"@types/lodash": "^4.14.191",
|
||||
@ -49,7 +48,6 @@
|
||||
"dependencies": {
|
||||
"@babel/core": "^7.18.13",
|
||||
"@babel/preset-typescript": "^7.18.6",
|
||||
"@types/jest": "^29.5.1",
|
||||
"@vant/eslint-config": "^4.0.0",
|
||||
"@vant/touch-emulator": "^1.4.0",
|
||||
"@vitejs/plugin-vue": "^4.0.0",
|
||||
@ -66,10 +64,6 @@
|
||||
"hash-sum": "^2.0.0",
|
||||
"highlight.js": "^11.6.0",
|
||||
"husky": "^8.0.1",
|
||||
"jest": "^29.5.0",
|
||||
"jest-canvas-mock": "^2.4.0",
|
||||
"jest-environment-jsdom": "^29.1.2",
|
||||
"jest-serializer-html": "^7.1.0",
|
||||
"less": "^4.1.3",
|
||||
"lodash": "^4.17.21",
|
||||
"markdown-it": "^13.0.1",
|
||||
|
@ -22,39 +22,6 @@ program
|
||||
return lint();
|
||||
});
|
||||
|
||||
program
|
||||
.command('test')
|
||||
.description('Run unit tests through jest')
|
||||
.option(
|
||||
'--watch',
|
||||
'Watch files for changes and rerun tests related to changed files',
|
||||
)
|
||||
.option(
|
||||
'--clearCache',
|
||||
'Clears the configured Jest cache directory and then exits',
|
||||
)
|
||||
.option(
|
||||
'--changedSince <changedSince>',
|
||||
'Runs tests related to the changes since the provided branch or commit hash',
|
||||
)
|
||||
.option(
|
||||
'--logHeapUsage',
|
||||
'Logs the heap usage after every test. Useful to debug memory leaks',
|
||||
)
|
||||
.option(
|
||||
'--runInBand',
|
||||
'Run all tests serially in the current process, rather than creating a worker pool of child processes that run tests',
|
||||
)
|
||||
.option(
|
||||
'--updateSnapshot',
|
||||
'Re-record every snapshot that fails during this test run',
|
||||
)
|
||||
.option('--debug', 'Print debugging info about your Jest config')
|
||||
.action(async (options) => {
|
||||
const { test } = await import('./commands/jest.js');
|
||||
return test(options);
|
||||
});
|
||||
|
||||
program
|
||||
.command('clean')
|
||||
.description('Clean all dist files')
|
||||
|
@ -1,47 +0,0 @@
|
||||
import jest from 'jest';
|
||||
import { setNodeEnv } from '../common/index.js';
|
||||
import { genPackageEntry } from '../compiler/gen-package-entry.js';
|
||||
import {
|
||||
ROOT,
|
||||
JEST_CONFIG_FILE,
|
||||
PACKAGE_ENTRY_FILE,
|
||||
} from '../common/constant.js';
|
||||
import type { Config } from '@jest/types';
|
||||
|
||||
export function test(command: Config.Argv) {
|
||||
setNodeEnv('test');
|
||||
|
||||
genPackageEntry({
|
||||
outputPath: PACKAGE_ENTRY_FILE,
|
||||
});
|
||||
|
||||
const config = {
|
||||
rootDir: ROOT,
|
||||
watch: command.watch,
|
||||
debug: command.debug,
|
||||
config: JEST_CONFIG_FILE,
|
||||
runInBand: command.runInBand,
|
||||
clearCache: command.clearCache,
|
||||
changedSince: command.changedSince,
|
||||
logHeapUsage: command.logHeapUsage,
|
||||
updateSnapshot: command.updateSnapshot,
|
||||
// make jest tests faster
|
||||
// see: https://ivantanev.com/make-jest-faster/
|
||||
maxWorkers: '50%',
|
||||
} as Config.Argv;
|
||||
|
||||
jest
|
||||
.runCLI(config, [ROOT])
|
||||
.then((response) => {
|
||||
if (!response.results.success && !command.watch) {
|
||||
process.exit(1);
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
|
||||
if (!command.watch) {
|
||||
process.exit(1);
|
||||
}
|
||||
});
|
||||
}
|
@ -40,7 +40,6 @@ export const STYLE_DEPS_JSON_FILE = join(DIST_DIR, 'style-deps.json');
|
||||
|
||||
// Config files
|
||||
export const POSTCSS_CONFIG_FILE = join(CJS_DIR, 'postcss.config.cjs');
|
||||
export const JEST_CONFIG_FILE = join(CJS_DIR, 'jest.config.cjs');
|
||||
|
||||
export const SCRIPT_EXTS = [
|
||||
'.js',
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { raf, cancelRaf } from '../src/utils';
|
||||
|
||||
test('raf', async () => {
|
||||
const spy = jest.fn();
|
||||
const spy = vi.fn();
|
||||
raf(spy);
|
||||
|
||||
expect(spy).toHaveBeenCalledTimes(1);
|
||||
|
@ -4,6 +4,9 @@
|
||||
"rules": {
|
||||
"prefer-object-spread": "off"
|
||||
},
|
||||
"globals": {
|
||||
"vi": true
|
||||
},
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["src/**/*"],
|
||||
|
@ -1,10 +0,0 @@
|
||||
module.exports = {
|
||||
testPathIgnorePatterns: ['/node_modules/'],
|
||||
collectCoverageFrom: [
|
||||
'src/**/*.{js,jsx,ts,tsx,vue}',
|
||||
'!src/lazyload/vue-lazyload/**',
|
||||
'!**/demo/**',
|
||||
'!**/test/**',
|
||||
'!**/lang/**',
|
||||
],
|
||||
};
|
@ -15,14 +15,15 @@
|
||||
"scripts": {
|
||||
"dev": "vant-cli dev",
|
||||
"lint": "vant-cli lint",
|
||||
"test": "vant-cli test",
|
||||
"test": "vitest run",
|
||||
"build": "vant-cli build",
|
||||
"build:site": "vant-cli build-site",
|
||||
"release": "cp ../../README.md ./ && vant-cli release --gitTag && rm ./README.md",
|
||||
"release:site": "pnpm build:site && npx gh-pages -d site-dist --add",
|
||||
"test:update": "vant-cli test --updateSnapshot",
|
||||
"test:watch": "vant-cli test --watch",
|
||||
"test:coverage": "open test/coverage/index.html"
|
||||
"test:update": "vitest run -u",
|
||||
"test:watch": "vitest",
|
||||
"test:coverage": "vitest run --coverage",
|
||||
"open:coverage": "open test/coverage/index.html"
|
||||
},
|
||||
"publishConfig": {
|
||||
"registry": "https://registry.npmjs.org/"
|
||||
@ -53,15 +54,22 @@
|
||||
"vue": "^3.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/jest": "^29.5.1",
|
||||
"@types/node": "^18.16.3",
|
||||
"@vant/area-data": "workspace:*",
|
||||
"@vant/cli": "workspace:*",
|
||||
"@vant/eslint-config": "workspace:*",
|
||||
"@vant/icons": "workspace:*",
|
||||
"@vitejs/plugin-vue": "^4.0.0",
|
||||
"@vitejs/plugin-vue-jsx": "^3.0.0",
|
||||
"@vitest/coverage-v8": "0.34.2",
|
||||
"@vue/runtime-core": "^3.3.4",
|
||||
"@vue/test-utils": "^2.3.2",
|
||||
"diffable-html": "^5.0.0",
|
||||
"jsdom": "^22.1.0",
|
||||
"typescript": "^5.0.4",
|
||||
"vite": "^4.4.2",
|
||||
"vitest": "^0.34.2",
|
||||
"vitest-canvas-mock": "^0.3.2",
|
||||
"vue": "^3.3.4",
|
||||
"vue-router": "^4.1.6"
|
||||
},
|
||||
|
@ -1,8 +1,9 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render default slot correctly 1`] = `
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--large van-action-bar-button"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--large van-action-bar-button"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,9 +1,10 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render default slot correctly 1`] = `
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-undefined van-action-bar-icon__icon">
|
||||
</div>
|
||||
@ -12,9 +13,10 @@ exports[`should render default slot correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render icon slot correctly 1`] = `
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-action-bar-icon__icon">
|
||||
Custom Icon
|
||||
@ -24,9 +26,10 @@ exports[`should render icon slot correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render icon slot with badge correctly 1`] = `
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-action-bar-icon__icon">
|
||||
Custom Icon
|
||||
@ -39,9 +42,10 @@ exports[`should render icon slot with badge correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render icon slot with dot correctly 1`] = `
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-action-bar-icon__icon">
|
||||
Custom Icon
|
||||
@ -53,9 +57,10 @@ exports[`should render icon slot with dot correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render icon-prefix correctly 1`] = `
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper my-icon my-icon-success van-action-bar-icon__icon">
|
||||
</div>
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
@ -6,42 +6,49 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<!--[-->
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-shop-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-shop-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Icon3
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last van-action-bar-button--first"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last van-action-bar-button--first"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -56,56 +63,66 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<!--[-->
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
5
|
||||
</div>
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-shop-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-shop-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
12
|
||||
</div>
|
||||
</div>
|
||||
Icon3
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--last van-action-bar-button--first"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--last van-action-bar-button--first"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -114,9 +131,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -131,42 +149,49 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<!--[-->
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style="color:#ee0a24;"
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style="color:#ee0a24;"
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-star van-action-bar-icon__icon"
|
||||
style="color:#ff5000;"
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-star van-action-bar-icon__icon"
|
||||
style="color:#ff5000;"
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Collected
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--last van-action-bar-button--first"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--last van-action-bar-button--first"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -175,9 +200,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -192,31 +218,36 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<!--[-->
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--last van-action-bar-button--first"
|
||||
style="color:white;background:#be99ff;border-color:#be99ff;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--last van-action-bar-button--first"
|
||||
style="color:white;background:#be99ff;border-color:#be99ff;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -225,9 +256,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style="color:white;background:#7232dd;border-color:#7232dd;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style="color:white;background:#7232dd;border-color:#7232dd;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,34 +1,38 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon">
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon">
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-shop-o van-action-bar-icon__icon">
|
||||
</div>
|
||||
Icon3
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last van-action-bar-button--first"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last van-action-bar-button--first"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -40,9 +44,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon">
|
||||
<div class="van-badge van-badge--top-right van-badge--dot van-badge--fixed">
|
||||
@ -50,9 +55,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon">
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed">
|
||||
@ -61,9 +67,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-shop-o van-action-bar-icon__icon">
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed">
|
||||
@ -72,8 +79,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
Icon3
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--first"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--first"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -81,8 +89,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -94,36 +103,42 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style="color: rgb(238, 10, 36);"
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon"
|
||||
style="color: rgb(238, 10, 36);"
|
||||
>
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon">
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-star van-action-bar-icon__icon"
|
||||
style="color: rgb(255, 80, 0);"
|
||||
<div
|
||||
class="van-badge__wrapper van-icon van-icon-star van-action-bar-icon__icon"
|
||||
style="color: rgb(255, 80, 0);"
|
||||
>
|
||||
</div>
|
||||
Collected
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--first"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--first"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -131,8 +146,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -144,25 +160,28 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-chat-o van-action-bar-icon__icon">
|
||||
</div>
|
||||
Icon1
|
||||
</div>
|
||||
<div role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
<div
|
||||
role="button"
|
||||
class="van-action-bar-icon"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-badge__wrapper van-icon van-icon-cart-o van-action-bar-icon__icon">
|
||||
</div>
|
||||
Icon2
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--first"
|
||||
style="color: white; border-color: #be99ff; background: rgb(190, 153, 255);"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--large van-action-bar-button van-action-bar-button--warning van-action-bar-button--first"
|
||||
style="color: white; border-color: #be99ff; background: rgb(190, 153, 255);"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -170,9 +189,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style="color: white; background: rgb(114, 50, 221); border-color: #7232dd;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--large van-action-bar-button van-action-bar-button--danger van-action-bar-button--last"
|
||||
style="color: white; background: rgb(114, 50, 221); border-color: #7232dd;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should allow to disable safe-area-inset-bottom prop 1`] = `
|
||||
<div class="van-action-bar">
|
||||
@ -6,8 +6,9 @@ exports[`should allow to disable safe-area-inset-bottom prop 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render placeholder element when using placeholder prop 1`] = `
|
||||
<div class="van-action-bar__placeholder"
|
||||
style="height: 50px;"
|
||||
<div
|
||||
class="van-action-bar__placeholder"
|
||||
style="height: 50px;"
|
||||
>
|
||||
<div class="van-action-bar van-safe-area-bottom">
|
||||
</div>
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,56 +1,65 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Basic Usage
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Show Cancel Button
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Show Description
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -58,19 +67,22 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Option Status
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -78,19 +90,22 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Custom Panel
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
|
@ -1,10 +1,11 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -14,9 +15,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -26,9 +28,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -40,9 +43,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -54,9 +58,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -67,74 +72,84 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<transition-stub name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<transition-stub
|
||||
name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<transition-stub
|
||||
name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<transition-stub
|
||||
name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<transition-stub
|
||||
name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<transition-stub
|
||||
name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
</transition-stub>
|
||||
`;
|
||||
|
@ -1,45 +1,53 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should allow to custom close icon with closeIcon prop 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-cross van-action-sheet__close van-haptics-feedback">
|
||||
</i>
|
||||
"<i class=\\"van-badge__wrapper van-icon van-icon-cross van-action-sheet__close van-haptics-feedback\\">
|
||||
<!---->
|
||||
<!---->
|
||||
<!---->
|
||||
</i>"
|
||||
`;
|
||||
|
||||
exports[`should render action slot correctly 1`] = `
|
||||
<button type="button"
|
||||
class="van-action-sheet__item"
|
||||
<button
|
||||
type="button"
|
||||
class="van-action-sheet__item"
|
||||
>
|
||||
name: Option, index: 0
|
||||
</button>
|
||||
`;
|
||||
|
||||
exports[`should render cancel slot correctly 1`] = `
|
||||
<button type="button"
|
||||
class="van-action-sheet__cancel"
|
||||
<button
|
||||
type="button"
|
||||
class="van-action-sheet__cancel"
|
||||
>
|
||||
Custom Cancel
|
||||
</button>
|
||||
`;
|
||||
|
||||
exports[`should render default slot correctly 1`] = `
|
||||
<transition-stub name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<transition-stub
|
||||
name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-overlay">
|
||||
</div>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
<div role="dialog"
|
||||
tabindex="0"
|
||||
class="van-popup van-popup--round van-popup--bottom van-safe-area-bottom van-action-sheet"
|
||||
<div
|
||||
role="dialog"
|
||||
tabindex="0"
|
||||
class="van-popup van-popup--round van-popup--bottom van-safe-area-bottom van-action-sheet"
|
||||
>
|
||||
<div class="van-action-sheet__header">
|
||||
Title
|
||||
@ -66,8 +74,9 @@ exports[`should render description slot when match snapshot 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render subname correctly 1`] = `
|
||||
<button type="button"
|
||||
class="van-action-sheet__item"
|
||||
<button
|
||||
type="button"
|
||||
class="van-action-sheet__item"
|
||||
>
|
||||
<span class="van-action-sheet__name">
|
||||
Option
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -23,7 +23,7 @@ test('should emit select event after clicking option', async () => {
|
||||
});
|
||||
|
||||
test('should call callback function after clicking option', () => {
|
||||
const callback = jest.fn();
|
||||
const callback = vi.fn();
|
||||
const wrapper = mount(ActionSheet, {
|
||||
props: {
|
||||
show: true,
|
||||
@ -230,7 +230,7 @@ test('should close after clicking option if close-on-click-action prop is true',
|
||||
});
|
||||
|
||||
test('should emit click-overlay event and closed after clicking the overlay', () => {
|
||||
const onClickOverlay = jest.fn();
|
||||
const onClickOverlay = vi.fn();
|
||||
const wrapper = mount(ActionSheet, {
|
||||
props: {
|
||||
show: true,
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
@ -7,13 +7,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-address-edit__fields">
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Name
|
||||
</label>
|
||||
@ -21,23 +23,26 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Phone
|
||||
</label>
|
||||
@ -45,26 +50,30 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
@ -72,30 +81,34 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-field van-address-edit-detail">
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Address
|
||||
</label>
|
||||
@ -103,11 +116,12 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<textarea id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
<textarea
|
||||
id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</textarea>
|
||||
</div>
|
||||
@ -115,28 +129,31 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--center van-cell--borderless van-address-edit__default">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Set as the default address
|
||||
</span>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div role="switch"
|
||||
class="van-switch"
|
||||
style
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="switch"
|
||||
class="van-switch"
|
||||
style
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-switch__node">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-address-edit__buttons">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
style
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -144,9 +161,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
@ -6,61 +6,68 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-address-edit__fields">
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Name
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Phone
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -69,20 +76,22 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-cell van-field van-address-edit-detail">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Address
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<textarea id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
style="height: auto;"
|
||||
<textarea
|
||||
id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
style="height: auto;"
|
||||
>
|
||||
</textarea>
|
||||
</div>
|
||||
@ -95,18 +104,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Set as the default address
|
||||
</span>
|
||||
</div>
|
||||
<div role="switch"
|
||||
class="van-switch"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="switch"
|
||||
class="van-switch"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-switch__node">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-address-edit__buttons">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -114,8 +125,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should allow to custom validator with validator prop 1`] = `
|
||||
<div class="van-field__error-message">
|
||||
@ -11,61 +11,68 @@ exports[`should render AddressEdit correctly 1`] = `
|
||||
<div class="van-address-edit__fields">
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Name
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Phone
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -74,19 +81,21 @@ exports[`should render AddressEdit correctly 1`] = `
|
||||
</div>
|
||||
<div class="van-cell van-field van-address-edit-detail">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Address
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<textarea id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
<textarea
|
||||
id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</textarea>
|
||||
</div>
|
||||
@ -94,8 +103,9 @@ exports[`should render AddressEdit correctly 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-address-edit__buttons">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -112,61 +122,68 @@ exports[`should render AddressEdit with props correctly 1`] = `
|
||||
<div class="van-address-edit__fields">
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Name
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Phone
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -175,19 +192,21 @@ exports[`should render AddressEdit with props correctly 1`] = `
|
||||
</div>
|
||||
<div class="van-cell van-field van-address-edit-detail">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Address
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<textarea id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
<textarea
|
||||
id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</textarea>
|
||||
</div>
|
||||
@ -200,18 +219,20 @@ exports[`should render AddressEdit with props correctly 1`] = `
|
||||
Set as the default address
|
||||
</span>
|
||||
</div>
|
||||
<div role="switch"
|
||||
class="van-switch van-switch--on"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="switch"
|
||||
class="van-switch van-switch--on"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-switch__node">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-address-edit__buttons">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-edit__button"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -226,20 +247,22 @@ exports[`should render AddressEdit with props correctly 1`] = `
|
||||
exports[`should valid address detail and render error message correctly 1`] = `
|
||||
<div class="van-cell van-field van-address-edit-detail">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Address
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<textarea id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
style="height: auto;"
|
||||
<textarea
|
||||
id="van-field-input"
|
||||
rows="1"
|
||||
class="van-field__control"
|
||||
placeholder="Address"
|
||||
aria-labelledby="van-field-label"
|
||||
style="height: auto;"
|
||||
>
|
||||
</textarea>
|
||||
</div>
|
||||
@ -251,25 +274,28 @@ exports[`should valid address detail and render error message correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should valid area code and render error message correctly 1`] = `
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -281,19 +307,21 @@ exports[`should valid area code and render error message correctly 1`] = `
|
||||
exports[`should valid name and render error message correctly 1`] = `
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Name
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Name"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
<div class="van-field__error-message">
|
||||
@ -306,19 +334,21 @@ exports[`should valid name and render error message correctly 1`] = `
|
||||
exports[`should valid tel and render error message correctly 1`] = `
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Phone
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="tel"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
placeholder="Phone"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
<div class="van-field__error-message">
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,31 +1,36 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-address-list">
|
||||
<div class="van-radio-group"
|
||||
role="radiogroup"
|
||||
<div
|
||||
class="van-radio-group"
|
||||
role="radiogroup"
|
||||
>
|
||||
<!--[-->
|
||||
<!--[-->
|
||||
<div class="van-address-item">
|
||||
<div class="van-cell van-cell--borderless">
|
||||
<div class="van-cell__title van-address-item__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-address-item__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-radio__icon van-radio__icon--round van-radio__icon--checked"
|
||||
style="font-size:18px;"
|
||||
<div
|
||||
class="van-radio__icon van-radio__icon--round van-radio__icon--checked"
|
||||
style="font-size:18px;"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -35,8 +40,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-address-item__name">
|
||||
John Snow 13000000000
|
||||
<span style
|
||||
class="van-tag van-tag--round van-tag--primary van-address-item__tag"
|
||||
<span
|
||||
style
|
||||
class="van-tag van-tag--round van-tag--primary van-address-item__tag"
|
||||
>
|
||||
<!--[-->
|
||||
Default
|
||||
@ -49,8 +55,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<!--[-->
|
||||
<i class="van-badge__wrapper van-icon van-icon-edit van-address-item__edit"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-edit van-address-item__edit"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -58,21 +65,25 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-address-item">
|
||||
<div class="van-cell van-cell--borderless">
|
||||
<div class="van-cell__title van-address-item__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-address-item__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-radio__icon van-radio__icon--round"
|
||||
style="font-size:18px;"
|
||||
<div
|
||||
class="van-radio__icon van-radio__icon--round"
|
||||
style="font-size:18px;"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -90,8 +101,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<!--[-->
|
||||
<i class="van-badge__wrapper van-icon van-icon-edit van-address-item__edit"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-edit van-address-item__edit"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -104,8 +116,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-address-item van-address-item--disabled">
|
||||
<div class="van-cell van-cell--borderless">
|
||||
<div class="van-cell__title van-address-item__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-address-item__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-address-item__name">
|
||||
@ -116,17 +129,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<!--[-->
|
||||
<i class="van-badge__wrapper van-icon van-icon-edit van-address-item__edit"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-edit van-address-item__edit"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-address-list__bottom van-safe-area-bottom">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-list__add"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-list__add"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,21 +1,24 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-address-list">
|
||||
<div class="van-radio-group"
|
||||
role="radiogroup"
|
||||
<div
|
||||
class="van-radio-group"
|
||||
role="radiogroup"
|
||||
>
|
||||
<div class="van-address-item">
|
||||
<div class="van-cell van-cell--borderless">
|
||||
<div class="van-cell__title van-address-item__title">
|
||||
<div role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-radio__icon van-radio__icon--round van-radio__icon--checked"
|
||||
style="font-size: 18px;"
|
||||
<div
|
||||
class="van-radio__icon van-radio__icon--round van-radio__icon--checked"
|
||||
style="font-size: 18px;"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
</i>
|
||||
@ -23,10 +26,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<span class="van-radio__label">
|
||||
<div class="van-address-item__name">
|
||||
John Snow 13000000000
|
||||
<transition-stub appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
class="van-address-item__tag"
|
||||
<transition-stub
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
class="van-address-item__tag"
|
||||
>
|
||||
<span class="van-tag van-tag--round van-tag--primary">
|
||||
Default
|
||||
@ -46,13 +50,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-address-item">
|
||||
<div class="van-cell van-cell--borderless">
|
||||
<div class="van-cell__title van-address-item__title">
|
||||
<div role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-radio"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-radio__icon van-radio__icon--round"
|
||||
style="font-size: 18px;"
|
||||
<div
|
||||
class="van-radio__icon van-radio__icon--round"
|
||||
style="font-size: 18px;"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
</i>
|
||||
@ -90,8 +96,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-address-list__bottom van-safe-area-bottom">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-list__add"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-list__add"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,14 +1,16 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render tag slot correctly 1`] = `
|
||||
<div class="van-address-list">
|
||||
<div class="van-radio-group"
|
||||
role="radiogroup"
|
||||
<div
|
||||
class="van-radio-group"
|
||||
role="radiogroup"
|
||||
>
|
||||
</div>
|
||||
<div class="van-address-list__bottom van-safe-area-bottom">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-list__add"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-address-list__add"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
@ -7,51 +7,58 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -60,14 +67,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing City
|
||||
@ -76,95 +85,106 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Dongcheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Xicheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Chaoyang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Fengtai
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Haidian
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Fangshan
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Tongzhou
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Shunyi
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Changping
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Daxing
|
||||
@ -173,12 +193,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -189,51 +211,58 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 66px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 66px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -242,50 +271,56 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 22px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 22px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hangzhou
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Ningbo
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Wenzhou
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Jiaxin
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Lishui
|
||||
@ -294,50 +329,56 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Lucheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Wencheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Shuntai
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Ruian
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Yueqing
|
||||
@ -346,12 +387,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -362,51 +405,58 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -415,14 +465,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing City
|
||||
@ -431,12 +483,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -447,60 +501,68 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height:264px;"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Choose
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -509,14 +571,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Choose
|
||||
@ -525,14 +589,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform:translate3d(0, 110px, 0);transition-duration:0ms;transition-property:none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<!--[-->
|
||||
<li role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height:44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Choose
|
||||
@ -541,12 +607,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size:100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height:44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,52 +1,59 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -55,13 +62,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing City
|
||||
@ -70,94 +79,105 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Dongcheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Xicheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Chaoyang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Fengtai
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Haidian
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Fangshan
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Tongzhou
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Shunyi
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Changping
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Daxing
|
||||
@ -165,12 +185,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -179,49 +201,56 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 66px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 66px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -230,49 +259,55 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 22px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 22px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hangzhou
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Ningbo
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Wenzhou
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Jiaxin
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Lishui
|
||||
@ -281,49 +316,55 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Lucheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Wencheng
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Shuntai
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Ruian
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Yueqing
|
||||
@ -331,12 +372,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -345,49 +388,56 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -396,13 +446,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing City
|
||||
@ -410,12 +462,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -424,58 +478,66 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<div class="van-picker__title van-ellipsis">
|
||||
Title
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Choose
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Beijing
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Zhejiang
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Hong Kong
|
||||
@ -484,13 +546,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Choose
|
||||
@ -499,13 +563,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
Choose
|
||||
@ -513,12 +579,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,26 +1,30 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render columns-top、columns-bottom slot correctly 1`] = `
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
Top
|
||||
<div class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
</ul>
|
||||
</div>
|
||||
@ -31,14 +35,16 @@ exports[`should render columns-top、columns-bottom slot correctly 1`] = `
|
||||
|
||||
exports[`should render title slot correctly 1`] = `
|
||||
<div class="van-picker__toolbar">
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
Custom Title
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
@ -48,37 +54,43 @@ exports[`should render title slot correctly 1`] = `
|
||||
exports[`should render two columns when columns-num prop is two 1`] = `
|
||||
<div class="van-picker van-area">
|
||||
<div class="van-picker__toolbar">
|
||||
<button type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__cancel van-haptics-feedback"
|
||||
>
|
||||
Cancel
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
<button
|
||||
type="button"
|
||||
class="van-picker__confirm van-haptics-feedback"
|
||||
>
|
||||
Confirm
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
<div
|
||||
class="van-picker__columns"
|
||||
style="height: 264px;"
|
||||
>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
北京市
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
天津市
|
||||
@ -87,22 +99,25 @@ exports[`should render two columns when columns-num prop is two 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker-column">
|
||||
<ul style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
<ul
|
||||
style="transform: translate3d(0, 110px, 0); transition-duration: 0ms; transition-property: none;"
|
||||
class="van-picker-column__wrapper"
|
||||
>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
北京市
|
||||
</div>
|
||||
</li>
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
县
|
||||
@ -110,12 +125,14 @@ exports[`should render two columns when columns-num prop is two 1`] = `
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
<div
|
||||
class="van-picker__mask"
|
||||
style="background-size: 100% 110px;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
<div
|
||||
class="van-hairline-unset--top-bottom van-picker__frame"
|
||||
style="height: 44px;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -123,10 +140,11 @@ exports[`should render two columns when columns-num prop is two 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should watch modelValue prop and render correctly 1`] = `
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
北京市
|
||||
@ -135,10 +153,11 @@ exports[`should watch modelValue prop and render correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should watch modelValue prop and render correctly 2`] = `
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
天津市
|
||||
@ -147,10 +166,11 @@ exports[`should watch modelValue prop and render correctly 2`] = `
|
||||
`;
|
||||
|
||||
exports[`should watch modelValue prop and render correctly 3`] = `
|
||||
<li role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
<li
|
||||
role="button"
|
||||
style="height: 44px;"
|
||||
tabindex="0"
|
||||
class="van-picker-column__item van-picker-column__item--selected"
|
||||
>
|
||||
<div class="van-ellipsis">
|
||||
北京市
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,13 +1,14 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-tabs van-tabs--line">
|
||||
<!--[-->
|
||||
<div class="van-tabs__wrap">
|
||||
<div role="tablist"
|
||||
class="van-tabs__nav van-tabs__nav--line van-tabs__nav--complete"
|
||||
style
|
||||
aria-orientation="horizontal"
|
||||
<div
|
||||
role="tablist"
|
||||
class="van-tabs__nav van-tabs__nav--line van-tabs__nav--complete"
|
||||
style
|
||||
aria-orientation="horizontal"
|
||||
>
|
||||
<!--[-->
|
||||
</div>
|
||||
@ -15,44 +16,49 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-tabs__content">
|
||||
<!--[-->
|
||||
<!--[-->
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-0"
|
||||
style="display:none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-0"
|
||||
style="display:none;"
|
||||
>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-1"
|
||||
style="display:none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-1"
|
||||
style="display:none;"
|
||||
>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-2"
|
||||
style="display:none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-2"
|
||||
style="display:none;"
|
||||
>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-3"
|
||||
style="display:none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-3"
|
||||
style="display:none;"
|
||||
>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-4"
|
||||
style="display:none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-4"
|
||||
style="display:none;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,80 +1,88 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-tabs van-tabs--line">
|
||||
<div class="van-tabs__wrap">
|
||||
<div role="tablist"
|
||||
class="van-tabs__nav van-tabs__nav--line van-tabs__nav--complete"
|
||||
aria-orientation="horizontal"
|
||||
<div
|
||||
role="tablist"
|
||||
class="van-tabs__nav van-tabs__nav--line van-tabs__nav--complete"
|
||||
aria-orientation="horizontal"
|
||||
>
|
||||
<div id="van-tabs-0"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow van-tab--active"
|
||||
tabindex="0"
|
||||
aria-selected="true"
|
||||
aria-controls="van-tab"
|
||||
<div
|
||||
id="van-tabs-0"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow van-tab--active"
|
||||
tabindex="0"
|
||||
aria-selected="true"
|
||||
aria-controls="van-tab"
|
||||
>
|
||||
<span class="van-tab__text">
|
||||
Basic Usage
|
||||
</span>
|
||||
</div>
|
||||
<div id="van-tabs-1"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
<div
|
||||
id="van-tabs-1"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
>
|
||||
<span class="van-tab__text">
|
||||
Custom Position
|
||||
</span>
|
||||
</div>
|
||||
<div id="van-tabs-2"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
<div
|
||||
id="van-tabs-2"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
>
|
||||
<span class="van-tab__text">
|
||||
Custom Content
|
||||
</span>
|
||||
</div>
|
||||
<div id="van-tabs-3"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
<div
|
||||
id="van-tabs-3"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
>
|
||||
<span class="van-tab__text">
|
||||
Set Scroll Target
|
||||
</span>
|
||||
</div>
|
||||
<div id="van-tabs-4"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
<div
|
||||
id="van-tabs-4"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--grow"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
>
|
||||
<span class="van-tab__text">
|
||||
Immediate Scroll
|
||||
</span>
|
||||
</div>
|
||||
<div class="van-tabs__line"
|
||||
style="transform: translateX(50px) translateX(-50%);"
|
||||
<div
|
||||
class="van-tabs__line"
|
||||
style="transform: translateX(50px) translateX(-50%);"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-tabs__content">
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="0"
|
||||
aria-labelledby="van-tabs-0"
|
||||
style
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="0"
|
||||
aria-labelledby="van-tabs-0"
|
||||
style
|
||||
>
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title">
|
||||
@ -429,36 +437,40 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-back-top__placeholder">
|
||||
</div>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-1"
|
||||
style="display: none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-1"
|
||||
style="display: none;"
|
||||
>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-2"
|
||||
style="display: none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-2"
|
||||
style="display: none;"
|
||||
>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-3"
|
||||
style="display: none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-3"
|
||||
style="display: none;"
|
||||
>
|
||||
</div>
|
||||
<div id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-4"
|
||||
style="display: none;"
|
||||
<div
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
class="van-tab__panel"
|
||||
tabindex="-1"
|
||||
aria-labelledby="van-tabs-4"
|
||||
style="display: none;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,11 +1,13 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render correctly when SSR 1`] = `
|
||||
<div class="van-back-top"
|
||||
style
|
||||
<div
|
||||
class="van-back-top"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-back-top van-back-top__icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-back-top van-back-top__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -33,7 +33,7 @@ test('should allow position prop to contain unit', async () => {
|
||||
});
|
||||
|
||||
test('should emit click event after clicked', async () => {
|
||||
const windowScroll = jest.fn();
|
||||
const windowScroll = vi.fn();
|
||||
window.scrollTo = windowScroll;
|
||||
|
||||
const root = document.createElement('div');
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import { BackTop } from '..';
|
||||
import { renderComponentToString } from '../../../test';
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
@ -8,8 +8,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
5
|
||||
</div>
|
||||
@ -18,8 +19,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
10
|
||||
</div>
|
||||
@ -28,8 +30,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
Hot
|
||||
</div>
|
||||
@ -38,8 +41,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -50,8 +54,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
9+
|
||||
</div>
|
||||
@ -60,8 +65,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
20+
|
||||
</div>
|
||||
@ -70,8 +76,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
99+
|
||||
</div>
|
||||
@ -83,8 +90,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background:#1989fa;"
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background:#1989fa;"
|
||||
>
|
||||
5
|
||||
</div>
|
||||
@ -93,8 +101,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background:#1989fa;"
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background:#1989fa;"
|
||||
>
|
||||
10
|
||||
</div>
|
||||
@ -103,8 +112,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style="background:#1989fa;"
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style="background:#1989fa;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -115,12 +125,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<i class="van-badge__wrapper van-icon van-icon-success badge-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success badge-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -130,12 +142,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<i class="van-badge__wrapper van-icon van-icon-cross badge-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-cross badge-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -145,12 +159,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<i class="van-badge__wrapper van-icon van-icon-down badge-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-down badge-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -163,8 +179,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-left van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--top-left van-badge--fixed"
|
||||
style
|
||||
>
|
||||
10
|
||||
</div>
|
||||
@ -173,8 +190,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--bottom-left van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--bottom-left van-badge--fixed"
|
||||
style
|
||||
>
|
||||
10
|
||||
</div>
|
||||
@ -183,8 +201,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--bottom-right van-badge--fixed"
|
||||
style
|
||||
<div
|
||||
class="van-badge van-badge--bottom-right van-badge--fixed"
|
||||
style
|
||||
>
|
||||
10
|
||||
</div>
|
||||
@ -192,13 +211,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-badge van-badge--top-right"
|
||||
style="margin-left:16px;"
|
||||
<div
|
||||
class="van-badge van-badge--top-right"
|
||||
style="margin-left:16px;"
|
||||
>
|
||||
20
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right"
|
||||
style="margin-left:16px;"
|
||||
<div
|
||||
class="van-badge van-badge--top-right"
|
||||
style="margin-left:16px;"
|
||||
>
|
||||
99+
|
||||
</div>
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
@ -57,8 +57,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-badge__wrapper">
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background: rgb(25, 137, 250);"
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background: rgb(25, 137, 250);"
|
||||
>
|
||||
5
|
||||
</div>
|
||||
@ -66,8 +67,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-badge__wrapper">
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background: rgb(25, 137, 250);"
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--fixed"
|
||||
style="background: rgb(25, 137, 250);"
|
||||
>
|
||||
10
|
||||
</div>
|
||||
@ -75,8 +77,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-badge__wrapper">
|
||||
<div class="child">
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style="background: rgb(25, 137, 250);"
|
||||
<div
|
||||
class="van-badge van-badge--top-right van-badge--dot van-badge--fixed"
|
||||
style="background: rgb(25, 137, 250);"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -131,13 +134,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-badge van-badge--top-right"
|
||||
style="margin-left: 16px;"
|
||||
<div
|
||||
class="van-badge van-badge--top-right"
|
||||
style="margin-left: 16px;"
|
||||
>
|
||||
20
|
||||
</div>
|
||||
<div class="van-badge van-badge--top-right"
|
||||
style="margin-left: 16px;"
|
||||
<div
|
||||
class="van-badge van-badge--top-right"
|
||||
style="margin-left: 16px;"
|
||||
>
|
||||
99+
|
||||
</div>
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render content slot correctly 1`] = `
|
||||
<div class="van-badge van-badge--top-right">
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,54 +1,64 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
<div
|
||||
class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
>
|
||||
<div class="video">
|
||||
</div>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="100"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="100"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="101"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="101"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="102"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="102"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; top: 310px;"
|
||||
data-id="103"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; top: 310px;"
|
||||
data-id="103"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="104"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="104"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="105"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="105"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="106"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="106"
|
||||
>
|
||||
</span>
|
||||
</div>
|
||||
<div class="van-space van-space--horizontal van-space--align-center"
|
||||
style="margin-top: 10px;"
|
||||
<div
|
||||
class="van-space van-space--horizontal van-space--align-center"
|
||||
style="margin-top: 10px;"
|
||||
>
|
||||
<div class="van-space-item">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -60,56 +70,67 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
<div
|
||||
class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
>
|
||||
<div class="video">
|
||||
</div>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="100"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="100"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="101"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="101"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="102"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="102"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 310px;"
|
||||
data-id="103"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 310px;"
|
||||
data-id="103"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="104"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="104"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="105"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="105"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="106"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="106"
|
||||
>
|
||||
</span>
|
||||
</div>
|
||||
<div class="van-space van-space--horizontal van-space--align-center"
|
||||
style="margin-top: 10px;"
|
||||
<div
|
||||
class="van-space van-space--horizontal van-space--align-center"
|
||||
style="margin-top: 10px;"
|
||||
>
|
||||
<div class="van-space-item"
|
||||
style="margin-right: 8px;"
|
||||
<div
|
||||
class="van-space-item"
|
||||
style="margin-right: 8px;"
|
||||
>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--small van-button--disabled"
|
||||
disabled
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--small van-button--disabled"
|
||||
disabled
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -119,8 +140,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div class="van-space-item">
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--small"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--small"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,138 +1,165 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should auto play when only list props 1`] = `
|
||||
<div class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
<div
|
||||
class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
>
|
||||
<div class="video"
|
||||
style="width: 100%; height: 150px;"
|
||||
<div
|
||||
class="video"
|
||||
style="width: 100%; height: 150px;"
|
||||
>
|
||||
</div>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="100"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="100"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="101"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="101"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="102"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="102"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; top: 310px;"
|
||||
data-id="103"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; top: 310px;"
|
||||
data-id="103"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="104"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; top: 10px;"
|
||||
data-id="104"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="105"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; top: 110px;"
|
||||
data-id="105"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="106"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; top: 210px;"
|
||||
data-id="106"
|
||||
>
|
||||
</span>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`should emit "update:modelValue" when animationend 1`] = `
|
||||
<div class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
<div
|
||||
class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
>
|
||||
<div class="video"
|
||||
style="width: 100%; height: 150px;"
|
||||
<div
|
||||
class="video"
|
||||
style="width: 100%; height: 150px;"
|
||||
>
|
||||
</div>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="100"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="100"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="101"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="101"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="102"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="102"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 310px;"
|
||||
data-id="103"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 310px;"
|
||||
data-id="103"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="104"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="104"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="105"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="105"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="106"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="106"
|
||||
>
|
||||
</span>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`should not auto play use play function when use play function 1`] = `
|
||||
<div class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
<div
|
||||
class="van-barrage"
|
||||
style="--move-distance: -100px;"
|
||||
>
|
||||
<div class="video"
|
||||
style="width: 100%; height: 150px;"
|
||||
<div
|
||||
class="video"
|
||||
style="width: 100%; height: 150px;"
|
||||
>
|
||||
</div>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="100"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 0ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="100"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="101"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 300ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="101"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="102"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 600ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="102"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 310px;"
|
||||
data-id="103"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 900ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 310px;"
|
||||
data-id="103"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="104"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1200ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 10px;"
|
||||
data-id="104"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="105"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1500ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 110px;"
|
||||
data-id="105"
|
||||
>
|
||||
</span>
|
||||
<span class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="106"
|
||||
<span
|
||||
class="van-barrage__item"
|
||||
style="animation-duration: 4000ms; animation-delay: 1800ms; animation-name: van-barrage; animation-timing-function: linear; animation-play-state: paused; top: 210px;"
|
||||
data-id="106"
|
||||
>
|
||||
</span>
|
||||
</div>
|
||||
|
@ -1,13 +1,14 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="demo-button-row">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -16,9 +17,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -27,9 +29,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -39,9 +42,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</button>
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -50,9 +54,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -64,9 +69,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -74,9 +80,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -87,9 +94,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -97,9 +105,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -110,10 +119,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--disabled"
|
||||
style
|
||||
disabled
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--disabled"
|
||||
style
|
||||
disabled
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -121,10 +131,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--disabled"
|
||||
style
|
||||
disabled
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--disabled"
|
||||
style
|
||||
disabled
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -135,25 +146,30 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<div class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
<div
|
||||
class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
>
|
||||
<span class="van-loading__spinner van-loading__spinner--circular"
|
||||
style
|
||||
<span
|
||||
class="van-loading__spinner van-loading__spinner--circular"
|
||||
style
|
||||
>
|
||||
<svg class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
<svg
|
||||
class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
>
|
||||
<circle cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
<circle
|
||||
cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
>
|
||||
</circle>
|
||||
</svg>
|
||||
@ -161,17 +177,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<div class="van-loading van-loading--spinner van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
<div
|
||||
class="van-loading van-loading--spinner van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
>
|
||||
<span class="van-loading__spinner van-loading__spinner--spinner"
|
||||
style
|
||||
<span
|
||||
class="van-loading__spinner van-loading__spinner--spinner"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<i class="van-loading__line van-loading__line--1">
|
||||
@ -202,25 +221,30 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--loading"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--loading"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<div class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
<div
|
||||
class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
>
|
||||
<span class="van-loading__spinner van-loading__spinner--circular"
|
||||
style
|
||||
<span
|
||||
class="van-loading__spinner van-loading__spinner--circular"
|
||||
style
|
||||
>
|
||||
<svg class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
<svg
|
||||
class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
>
|
||||
<circle cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
<circle
|
||||
cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
>
|
||||
</circle>
|
||||
</svg>
|
||||
@ -234,9 +258,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--square"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--square"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -244,9 +269,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--round"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--round"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -257,25 +283,29 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper van-icon van-icon-plus van-button__icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-plus van-button__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper van-icon van-icon-plus van-button__icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-plus van-button__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -284,17 +314,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper van-icon van-button__icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-button__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<img class="van-icon__image"
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/user-active.png"
|
||||
<img
|
||||
class="van-icon__image"
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/user-active.png"
|
||||
>
|
||||
</i>
|
||||
<span class="van-button__text">
|
||||
@ -305,9 +338,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--large"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--large"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -316,9 +350,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -327,9 +362,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -338,9 +374,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--mini"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--mini"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -352,9 +389,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -366,9 +404,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -376,9 +415,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -389,9 +429,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color:white;background:#7232dd;border-color:#7232dd;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color:white;background:#7232dd;border-color:#7232dd;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -399,9 +440,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--plain"
|
||||
style="color:#7232dd;border-color:#7232dd;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--plain"
|
||||
style="color:#7232dd;border-color:#7232dd;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -409,9 +451,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color:white;background:linear-gradient(to right, #ff6034, #ee0a24);border:0;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color:white;background:linear-gradient(to right, #ff6034, #ee0a24);border:0;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -422,26 +465,30 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--normal van-button--round"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--normal van-button--round"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
<!--[-->
|
||||
<div class="van-swipe notice-swipe">
|
||||
<div style="transition-duration:500ms;transform:translateY(0px);"
|
||||
class="van-swipe__track van-swipe__track--vertical"
|
||||
<div
|
||||
style="transition-duration:500ms;transform:translateY(0px);"
|
||||
class="van-swipe__track van-swipe__track--vertical"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-swipe-item"
|
||||
style
|
||||
<div
|
||||
class="van-swipe-item"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
Do Task
|
||||
</div>
|
||||
<div class="van-swipe-item"
|
||||
style
|
||||
<div
|
||||
class="van-swipe-item"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
Lottery
|
||||
|
@ -1,10 +1,11 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="demo-button-row">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -12,8 +13,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -21,8 +23,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -31,8 +34,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</button>
|
||||
</div>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -40,8 +44,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--warning van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--warning van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -51,8 +56,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -60,8 +66,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -71,8 +78,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -80,8 +88,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--plain van-button--hairline van-hairline--surround"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -91,9 +100,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--disabled"
|
||||
disabled
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--disabled"
|
||||
disabled
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -101,9 +111,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--disabled"
|
||||
disabled
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--disabled"
|
||||
disabled
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -113,22 +124,26 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<div class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
<div
|
||||
class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
>
|
||||
<span class="van-loading__spinner van-loading__spinner--circular">
|
||||
<svg class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
<svg
|
||||
class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
>
|
||||
<circle cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
<circle
|
||||
cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
>
|
||||
</circle>
|
||||
</svg>
|
||||
@ -136,13 +151,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--loading"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<div class="van-loading van-loading--spinner van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
<div
|
||||
class="van-loading van-loading--spinner van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
>
|
||||
<span class="van-loading__spinner van-loading__spinner--spinner">
|
||||
<i class="van-loading__line van-loading__line--1">
|
||||
@ -173,22 +190,26 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--loading"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--loading"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<div class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
<div
|
||||
class="van-loading van-loading--circular van-button__loading"
|
||||
aria-live="polite"
|
||||
aria-busy="true"
|
||||
>
|
||||
<span class="van-loading__spinner van-loading__spinner--circular">
|
||||
<svg class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
<svg
|
||||
class="van-loading__circular"
|
||||
viewbox="25 25 50 50"
|
||||
>
|
||||
<circle cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
<circle
|
||||
cx="50"
|
||||
cy="50"
|
||||
r="20"
|
||||
fill="none"
|
||||
>
|
||||
</circle>
|
||||
</svg>
|
||||
@ -201,8 +222,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--square"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--square"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -210,8 +232,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--round"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--success van-button--normal van-button--round"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -221,16 +244,18 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper van-icon van-icon-plus van-button__icon">
|
||||
</i>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper van-icon van-icon-plus van-button__icon">
|
||||
@ -240,13 +265,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--plain"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper van-icon van-button__icon">
|
||||
<img class="van-icon__image"
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/user-active.png"
|
||||
<img
|
||||
class="van-icon__image"
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/user-active.png"
|
||||
>
|
||||
</i>
|
||||
<span class="van-button__text">
|
||||
@ -256,8 +283,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--large"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--large"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -265,8 +293,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -274,8 +303,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -283,8 +313,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--mini"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--mini"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -294,8 +325,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -305,8 +337,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -314,8 +347,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -325,9 +359,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color: white; background: rgb(114, 50, 221); border-color: #7232dd;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color: white; background: rgb(114, 50, 221); border-color: #7232dd;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -335,9 +370,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--plain"
|
||||
style="color: rgb(114, 50, 221); border-color: #7232dd;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--plain"
|
||||
style="color: rgb(114, 50, 221); border-color: #7232dd;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -345,9 +381,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color: white; border: 0px;"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
style="color: white; border: 0px;"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -357,22 +394,26 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</button>
|
||||
</div>
|
||||
<div>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--normal van-button--round"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--normal van-button--round"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
<div class="van-swipe notice-swipe">
|
||||
<div style="transition-duration: 0ms; transform: translateY(0px); height: 200px;"
|
||||
class="van-swipe__track van-swipe__track--vertical"
|
||||
<div
|
||||
style="transition-duration: 0ms; transform: translateY(0px); height: 200px;"
|
||||
class="van-swipe__track van-swipe__track--vertical"
|
||||
>
|
||||
<div class="van-swipe-item"
|
||||
style="height: 100px;"
|
||||
<div
|
||||
class="van-swipe-item"
|
||||
style="height: 100px;"
|
||||
>
|
||||
Do Task
|
||||
</div>
|
||||
<div class="van-swipe-item"
|
||||
style="height: 100px;"
|
||||
<div
|
||||
class="van-swipe-item"
|
||||
style="height: 100px;"
|
||||
>
|
||||
Lottery
|
||||
</div>
|
||||
|
@ -1,8 +1,9 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should change icon class prefix when using icon-prefix prop 1`] = `
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper my-icon my-icon-success van-button__icon">
|
||||
@ -12,8 +13,9 @@ exports[`should change icon class prefix when using icon-prefix prop 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render icon in the right side when setting icon-position to right 1`] = `
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<i class="van-badge__wrapper van-icon van-icon-plus van-button__icon">
|
||||
@ -23,8 +25,9 @@ exports[`should render icon in the right side when setting icon-position to righ
|
||||
`;
|
||||
|
||||
exports[`should render icon slot correctly 1`] = `
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<div class="van-button__icon">
|
||||
@ -38,8 +41,9 @@ exports[`should render icon slot correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render loading slot correctly 1`] = `
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--loading"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--normal van-button--loading"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
Custom Loading
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,56 +1,65 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Select Single Date
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Select Multiple Date
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Select Date Range
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -58,36 +67,42 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Select Single Date
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Select Date Range
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -95,121 +110,142 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Custom Color
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Custom Date Range
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Custom Confirm Text
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Custom Day Text
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Custom Position
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Max Range
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Custom First Day Of Week
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -217,8 +253,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-calendar"
|
||||
style="height:500px;"
|
||||
<div
|
||||
class="van-calendar"
|
||||
style="height:500px;"
|
||||
>
|
||||
<div class="van-calendar__header">
|
||||
<div class="van-calendar__header-title">
|
||||
@ -254,28 +291,34 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-calendar__body">
|
||||
<!--[-->
|
||||
<div class="van-calendar__month">
|
||||
<div role="grid"
|
||||
class="van-calendar__days"
|
||||
<div
|
||||
role="grid"
|
||||
class="van-calendar__days"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -284,28 +327,34 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-calendar__month-title">
|
||||
2012/2
|
||||
</div>
|
||||
<div role="grid"
|
||||
class="van-calendar__days"
|
||||
<div
|
||||
role="grid"
|
||||
class="van-calendar__days"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -314,28 +363,34 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-calendar__month-title">
|
||||
2012/3
|
||||
</div>
|
||||
<div role="grid"
|
||||
class="van-calendar__days"
|
||||
<div
|
||||
role="grid"
|
||||
class="van-calendar__days"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width:100%;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,10 +1,11 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -14,9 +15,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -26,9 +28,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -40,9 +43,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -52,9 +56,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -66,9 +71,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -78,9 +84,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -90,9 +97,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -102,9 +110,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -114,9 +123,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -126,9 +136,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -138,9 +149,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -152,8 +164,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-calendar"
|
||||
style="height: 500px;"
|
||||
<div
|
||||
class="van-calendar"
|
||||
style="height: 500px;"
|
||||
>
|
||||
<div class="van-calendar__header">
|
||||
<div class="van-calendar__header-title">
|
||||
@ -187,27 +200,33 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-calendar__body">
|
||||
<div class="van-calendar__month">
|
||||
<div role="grid"
|
||||
class="van-calendar__days"
|
||||
<div
|
||||
role="grid"
|
||||
class="van-calendar__days"
|
||||
>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -216,27 +235,33 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-calendar__month-title">
|
||||
2012/2
|
||||
</div>
|
||||
<div role="grid"
|
||||
class="van-calendar__days"
|
||||
<div
|
||||
role="grid"
|
||||
class="van-calendar__days"
|
||||
>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -245,27 +270,33 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-calendar__month-title">
|
||||
2012/3
|
||||
</div>
|
||||
<div role="grid"
|
||||
class="van-calendar__days"
|
||||
<div
|
||||
role="grid"
|
||||
class="van-calendar__days"
|
||||
>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
<div class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
<div
|
||||
class="van-calendar__day"
|
||||
style="width: 100%;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -275,18 +306,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<transition-stub name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<transition-stub
|
||||
name="van-fade"
|
||||
appear="true"
|
||||
persisted="false"
|
||||
css="true"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
</transition-stub>
|
||||
<transition-stub name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
name="van-popup-slide-bottom"
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
</transition-stub>
|
||||
`;
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`lazy-render prop 1`] = `
|
||||
<div class="van-calendar">
|
||||
@ -34,186 +34,218 @@ exports[`lazy-render prop 1`] = `
|
||||
</div>
|
||||
<div class="van-calendar__body">
|
||||
<div class="van-calendar__month">
|
||||
<div role="grid"
|
||||
class="van-calendar__days"
|
||||
<div
|
||||
role="grid"
|
||||
class="van-calendar__days"
|
||||
>
|
||||
<div class="van-calendar__month-mark">
|
||||
1
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-left: 71.42857142857143%;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-left: 71.42857142857143%;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
1
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
2
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
3
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
4
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
5
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
6
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
7
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
8
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
9
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
10
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
11
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
12
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
13
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
14
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
15
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
16
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
17
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
18
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day"
|
||||
tabindex="-1"
|
||||
>
|
||||
19
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--selected"
|
||||
tabindex="-1"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--selected"
|
||||
tabindex="-1"
|
||||
>
|
||||
<div class="van-calendar__selected-day">
|
||||
20
|
||||
</div>
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
21
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
22
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
23
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
24
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
25
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
26
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
27
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
28
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
29
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
30
|
||||
</div>
|
||||
<div role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
<div
|
||||
role="gridcell"
|
||||
style="margin-bottom: 0px;"
|
||||
class="van-calendar__day van-calendar__day--disabled"
|
||||
>
|
||||
31
|
||||
</div>
|
||||
@ -221,8 +253,9 @@ exports[`lazy-render prop 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-calendar__footer van-safe-area-bottom">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-calendar__confirm"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round van-calendar__confirm"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -305,7 +305,7 @@ test('row-height prop', async () => {
|
||||
|
||||
await later();
|
||||
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
expect(wrapper.find('.van-calendar__day').style.height).toEqual('50px');
|
||||
});
|
||||
|
||||
test('formatter prop', async () => {
|
||||
@ -339,7 +339,7 @@ test('formatter prop', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
});
|
||||
@ -360,7 +360,7 @@ test('should render title、footer、subtitle slot correctly', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
});
|
||||
@ -379,7 +379,7 @@ test('should render subtitle slot with params', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(
|
||||
wrapper.find('.van-calendar__header-subtitle').html(),
|
||||
@ -400,7 +400,7 @@ test('should render month-title slot correctly', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(wrapper.find('.van-calendar__month-title').html()).toMatchSnapshot();
|
||||
});
|
||||
@ -499,11 +499,11 @@ test('popup wrapper', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
|
||||
await wrapper.setProps({ show: true });
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
|
||||
@ -541,7 +541,9 @@ test('color prop when type is single', async () => {
|
||||
|
||||
await later();
|
||||
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
expect(wrapper.find('.van-calendar__selected-day').style.background).toEqual(
|
||||
'blue',
|
||||
);
|
||||
});
|
||||
|
||||
test('color prop when type is range', async () => {
|
||||
@ -556,13 +558,21 @@ test('color prop when type is range', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
expect(wrapper.find('.van-calendar__day--start').style.background).toEqual(
|
||||
'blue',
|
||||
);
|
||||
expect(wrapper.find('.van-calendar__day--middle').style.color).toEqual(
|
||||
'blue',
|
||||
);
|
||||
expect(wrapper.find('.van-calendar__day--end').style.background).toEqual(
|
||||
'blue',
|
||||
);
|
||||
});
|
||||
|
||||
test('close event', async () => {
|
||||
const onClose = jest.fn();
|
||||
const onClose = vi.fn();
|
||||
const wrapper = mount(Calendar, {
|
||||
props: {
|
||||
show: true,
|
||||
@ -590,7 +600,7 @@ test('should render top-info and bottom-info slot correctly', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(wrapper.find('.van-calendar__day').html()).toMatchSnapshot();
|
||||
});
|
||||
@ -621,7 +631,7 @@ test('should render confirm-text slot correctly', async () => {
|
||||
},
|
||||
});
|
||||
|
||||
await later();
|
||||
await later(50);
|
||||
|
||||
expect(wrapper.find('.van-calendar__confirm').html()).toMatchSnapshot();
|
||||
});
|
||||
|
@ -94,7 +94,7 @@ test('hide close icon when there is no title', async () => {
|
||||
});
|
||||
|
||||
test('allow-same-day prop', async () => {
|
||||
const onSelect = jest.fn();
|
||||
const onSelect = vi.fn();
|
||||
const wrapper = mount(Calendar, {
|
||||
props: {
|
||||
type: 'range',
|
||||
@ -249,7 +249,7 @@ test('should disabled prompt when using show-range-prompt prop', async () => {
|
||||
});
|
||||
|
||||
test('should emit overRange when exceeded max range', async () => {
|
||||
const onOverRange = jest.fn();
|
||||
const onOverRange = vi.fn();
|
||||
const wrapper = mount(Calendar, {
|
||||
props: {
|
||||
type: 'range',
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
@ -7,16 +7,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-card">
|
||||
<div class="van-card__header">
|
||||
<a class="van-card__thumb">
|
||||
<div class="van-image"
|
||||
style="width:100%;height:100%;"
|
||||
<div
|
||||
class="van-image"
|
||||
style="width:100%;height:100%;"
|
||||
>
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit:cover;"
|
||||
<img
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit:cover;"
|
||||
>
|
||||
<div class="van-image__loading">
|
||||
<i class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -60,24 +63,28 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-card">
|
||||
<div class="van-card__header">
|
||||
<a class="van-card__thumb">
|
||||
<div class="van-image"
|
||||
style="width:100%;height:100%;"
|
||||
<div
|
||||
class="van-image"
|
||||
style="width:100%;height:100%;"
|
||||
>
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit:cover;"
|
||||
<img
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit:cover;"
|
||||
>
|
||||
<div class="van-image__loading">
|
||||
<i class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-card__tag">
|
||||
<span style
|
||||
class="van-tag van-tag--mark van-tag--primary"
|
||||
<span
|
||||
style
|
||||
class="van-tag van-tag--mark van-tag--primary"
|
||||
>
|
||||
<!--[-->
|
||||
Tag
|
||||
@ -124,16 +131,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-card">
|
||||
<div class="van-card__header">
|
||||
<a class="van-card__thumb">
|
||||
<div class="van-image"
|
||||
style="width:100%;height:100%;"
|
||||
<div
|
||||
class="van-image"
|
||||
style="width:100%;height:100%;"
|
||||
>
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit:cover;"
|
||||
<img
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit:cover;"
|
||||
>
|
||||
<div class="van-image__loading">
|
||||
<i class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -149,14 +159,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Description
|
||||
</div>
|
||||
<!--[-->
|
||||
<span style="margin-right:5px;"
|
||||
class="van-tag van-tag--plain van-tag--primary"
|
||||
<span
|
||||
style="margin-right:5px;"
|
||||
class="van-tag van-tag--plain van-tag--primary"
|
||||
>
|
||||
<!--[-->
|
||||
Tag
|
||||
</span>
|
||||
<span style
|
||||
class="van-tag van-tag--plain van-tag--primary"
|
||||
<span
|
||||
style
|
||||
class="van-tag van-tag--plain van-tag--primary"
|
||||
>
|
||||
<!--[-->
|
||||
Tag
|
||||
@ -185,9 +197,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-card__footer">
|
||||
<!--[-->
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -196,9 +209,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,16 +1,18 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-card">
|
||||
<div class="van-card__header">
|
||||
<a class="van-card__thumb">
|
||||
<div class="van-image"
|
||||
style="width: 100%; height: 100%;"
|
||||
<div
|
||||
class="van-image"
|
||||
style="width: 100%; height: 100%;"
|
||||
>
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit: cover;"
|
||||
<img
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit: cover;"
|
||||
>
|
||||
<div class="van-image__loading">
|
||||
<i class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon">
|
||||
@ -54,12 +56,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-card">
|
||||
<div class="van-card__header">
|
||||
<a class="van-card__thumb">
|
||||
<div class="van-image"
|
||||
style="width: 100%; height: 100%;"
|
||||
<div
|
||||
class="van-image"
|
||||
style="width: 100%; height: 100%;"
|
||||
>
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit: cover;"
|
||||
<img
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit: cover;"
|
||||
>
|
||||
<div class="van-image__loading">
|
||||
<i class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon">
|
||||
@ -67,9 +71,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-card__tag">
|
||||
<transition-stub appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
<span class="van-tag van-tag--mark van-tag--primary">
|
||||
Tag
|
||||
@ -116,12 +121,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-card">
|
||||
<div class="van-card__header">
|
||||
<a class="van-card__thumb">
|
||||
<div class="van-image"
|
||||
style="width: 100%; height: 100%;"
|
||||
<div
|
||||
class="van-image"
|
||||
style="width: 100%; height: 100%;"
|
||||
>
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit: cover;"
|
||||
<img
|
||||
src="https://fastly.jsdelivr.net/npm/@vant/assets/ipad.jpeg"
|
||||
class="van-image__img"
|
||||
style="object-fit: cover;"
|
||||
>
|
||||
<div class="van-image__loading">
|
||||
<i class="van-badge__wrapper van-icon van-icon-photo van-image__loading-icon">
|
||||
@ -137,18 +144,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-card__desc van-ellipsis">
|
||||
Description
|
||||
</div>
|
||||
<transition-stub appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
style="margin-right: 5px;"
|
||||
<transition-stub
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
style="margin-right: 5px;"
|
||||
>
|
||||
<span class="van-tag van-tag--plain van-tag--primary">
|
||||
Tag
|
||||
</span>
|
||||
</transition-stub>
|
||||
<transition-stub appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
<span class="van-tag van-tag--plain van-tag--primary">
|
||||
Tag
|
||||
@ -177,8 +186,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-card__footer">
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -186,8 +196,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--default van-button--mini van-button--round"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`render thumb and tag slot correctly 1`] = `
|
||||
<div class="van-card">
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -2,7 +2,7 @@ import { Card } from '..';
|
||||
import { mount } from '../../../test';
|
||||
|
||||
test('should emit click event after clicked', () => {
|
||||
const onClick = jest.fn();
|
||||
const onClick = vi.fn();
|
||||
const wrapper = mount(Card, {
|
||||
props: {
|
||||
onClick,
|
||||
|
@ -1,20 +1,23 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
@ -22,17 +25,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -40,17 +45,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
@ -58,17 +66,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -76,17 +86,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
@ -94,17 +107,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -112,17 +127,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
@ -130,17 +148,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -148,17 +168,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
style
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
@ -166,17 +189,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<!--[-->
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
|
@ -1,26 +1,29 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -29,25 +32,28 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -56,25 +62,28 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -83,25 +92,28 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -110,25 +122,28 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-field"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title van-field__label">
|
||||
<label id="van-field-label"
|
||||
for="van-field-input"
|
||||
<label
|
||||
id="van-field-label"
|
||||
for="van-field-input"
|
||||
>
|
||||
Area
|
||||
</label>
|
||||
</div>
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<input type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
<input
|
||||
type="text"
|
||||
id="van-field-input"
|
||||
class="van-field__control"
|
||||
readonly
|
||||
placeholder="Select Area"
|
||||
aria-labelledby="van-field-label"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,30 +1,31 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should change close icon when using close-icon prop 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-success van-cascader__close-icon van-haptics-feedback">
|
||||
</i>
|
||||
"<i class=\\"van-badge__wrapper van-icon van-icon-success van-cascader__close-icon van-haptics-feedback\\">
|
||||
<!---->
|
||||
<!---->
|
||||
<!---->
|
||||
</i>"
|
||||
`;
|
||||
|
||||
exports[`should render option slot correctly 1`] = `
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
>
|
||||
Custom Option foo
|
||||
</li>
|
||||
"<li role=\\"menuitemradio\\" class=\\"van-cascader__option\\" tabindex=\\"-1\\" aria-checked=\\"false\\">Custom Option foo
|
||||
<!---->
|
||||
</li>"
|
||||
`;
|
||||
|
||||
exports[`should render options-top、options-bottom slots correctly 1`] = `
|
||||
<div class="van-tab__panel">
|
||||
Top, tab index: 0
|
||||
<ul role="menu"
|
||||
class="van-cascader__options"
|
||||
<ul
|
||||
role="menu"
|
||||
class="van-cascader__options"
|
||||
>
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option van-cascader__option--selected"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option van-cascader__option--selected"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<span>
|
||||
Zhejiang
|
||||
@ -32,10 +33,11 @@ exports[`should render options-top、options-bottom slots correctly 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-success van-cascader__selected-icon">
|
||||
</i>
|
||||
</li>
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
>
|
||||
<span>
|
||||
Jiangsu
|
||||
@ -46,17 +48,14 @@ exports[`should render options-top、options-bottom slots correctly 1`] = `
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`should render title slot correctly 1`] = `
|
||||
<h2 class="van-cascader__title">
|
||||
Custom Title
|
||||
</h2>
|
||||
`;
|
||||
exports[`should render title slot correctly 1`] = `"<h2 class=\\"van-cascader__title\\">Custom Title</h2>"`;
|
||||
|
||||
exports[`should select correct option when value changed 1`] = `
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option van-cascader__option--selected"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option van-cascader__option--selected"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<span>
|
||||
Wenzhou
|
||||
@ -76,68 +75,77 @@ exports[`should update tabs when previous tab is clicked 1`] = `
|
||||
</div>
|
||||
<div class="van-tabs van-tabs--line van-cascader__tabs">
|
||||
<div class="van-tabs__wrap">
|
||||
<div role="tablist"
|
||||
class="van-tabs__nav van-tabs__nav--line van-tabs__nav--shrink van-tabs__nav--complete"
|
||||
aria-orientation="horizontal"
|
||||
<div
|
||||
role="tablist"
|
||||
class="van-tabs__nav van-tabs__nav--line van-tabs__nav--shrink van-tabs__nav--complete"
|
||||
aria-orientation="horizontal"
|
||||
>
|
||||
<div id="van-tabs-0"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--shrink van-cascader__tab"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
<div
|
||||
id="van-tabs-0"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--shrink van-cascader__tab"
|
||||
tabindex="-1"
|
||||
aria-selected="false"
|
||||
aria-controls="van-tab"
|
||||
>
|
||||
<span class="van-tab__text">
|
||||
Jiangsu
|
||||
</span>
|
||||
</div>
|
||||
<div id="van-tabs-1"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--shrink van-tab--active van-cascader__tab van-cascader__tab--unselected"
|
||||
tabindex="0"
|
||||
aria-selected="true"
|
||||
aria-controls="van-tab"
|
||||
<div
|
||||
id="van-tabs-1"
|
||||
role="tab"
|
||||
class="van-tab van-tab--line van-tab--shrink van-tab--active van-cascader__tab van-cascader__tab--unselected"
|
||||
tabindex="0"
|
||||
aria-selected="true"
|
||||
aria-controls="van-tab"
|
||||
>
|
||||
<span class="van-tab__text">
|
||||
Select
|
||||
</span>
|
||||
</div>
|
||||
<div class="van-tabs__line"
|
||||
style="transform: translateX(50px) translateX(-50%); transition-duration: 0.3s;"
|
||||
<div
|
||||
class="van-tabs__line"
|
||||
style="transform: translateX(50px) translateX(-50%); transition-duration: 0.3s;"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-tabs__content van-tabs__content--animated">
|
||||
<div class="van-swipe van-tabs__track">
|
||||
<div style="transition-duration: 0ms; transform: translateX(0px); width: 200px;"
|
||||
class="van-swipe__track"
|
||||
<div
|
||||
style="transition-duration: 0ms; transform: translateX(0px); width: 200px;"
|
||||
class="van-swipe__track"
|
||||
>
|
||||
<div class="van-swipe-item van-tab__panel-wrapper"
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
tabindex="-1"
|
||||
aria-hidden="true"
|
||||
aria-labelledby="van-tabs-0"
|
||||
style="width: 100px;"
|
||||
<div
|
||||
class="van-swipe-item van-tab__panel-wrapper"
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
tabindex="-1"
|
||||
aria-hidden="true"
|
||||
aria-labelledby="van-tabs-0"
|
||||
style="width: 100px;"
|
||||
>
|
||||
<div class="van-tab__panel">
|
||||
<ul role="menu"
|
||||
class="van-cascader__options"
|
||||
<ul
|
||||
role="menu"
|
||||
class="van-cascader__options"
|
||||
>
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
>
|
||||
<span>
|
||||
Zhejiang
|
||||
</span>
|
||||
</li>
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option van-cascader__option--selected"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option van-cascader__option--selected"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<span>
|
||||
Jiangsu
|
||||
@ -148,40 +156,45 @@ exports[`should update tabs when previous tab is clicked 1`] = `
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-swipe-item van-tab__panel-wrapper"
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
tabindex="0"
|
||||
aria-hidden="false"
|
||||
aria-labelledby="van-tabs-1"
|
||||
style="width: 100px;"
|
||||
<div
|
||||
class="van-swipe-item van-tab__panel-wrapper"
|
||||
id="van-tab"
|
||||
role="tabpanel"
|
||||
tabindex="0"
|
||||
aria-hidden="false"
|
||||
aria-labelledby="van-tabs-1"
|
||||
style="width: 100px;"
|
||||
>
|
||||
<div class="van-tab__panel">
|
||||
<ul role="menu"
|
||||
class="van-cascader__options"
|
||||
<ul
|
||||
role="menu"
|
||||
class="van-cascader__options"
|
||||
>
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
>
|
||||
<span>
|
||||
Nanjing
|
||||
</span>
|
||||
</li>
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
>
|
||||
<span>
|
||||
Wuxi
|
||||
</span>
|
||||
</li>
|
||||
<li role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
<li
|
||||
role="menuitemradio"
|
||||
class="van-cascader__option"
|
||||
tabindex="-1"
|
||||
aria-checked="false"
|
||||
>
|
||||
<span>
|
||||
Xuzhou
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render title slot correctly 1`] = `
|
||||
<div class="van-cell-group__title">
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
@ -7,8 +7,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell-group van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -21,8 +22,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -44,8 +46,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell-group van-cell-group--inset">
|
||||
<!--[-->
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -58,8 +61,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -79,8 +83,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--large">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -93,8 +98,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--large">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -113,13 +119,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell">
|
||||
<i class="van-badge__wrapper van-icon van-icon-location-o van-cell__left-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-location-o van-cell__left-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -134,29 +142,34 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -167,18 +180,21 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Content
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -189,8 +205,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Content
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow-down van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow-down van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -198,36 +215,42 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
URL
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Vue Router
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -242,8 +265,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell-group van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -263,8 +287,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell-group van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
@ -280,19 +305,22 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<span class="custom-title">
|
||||
Cell title
|
||||
</span>
|
||||
<span style
|
||||
class="van-tag van-tag--primary"
|
||||
<span
|
||||
style
|
||||
class="van-tag van-tag--primary"
|
||||
>
|
||||
<!--[-->
|
||||
Tag
|
||||
@ -303,28 +331,32 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Content
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell">
|
||||
<i class="van-badge__wrapper van-icon van-icon-shop-o van-cell__left-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-shop-o van-cell__left-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
</span>
|
||||
</div>
|
||||
<!--[-->
|
||||
<i class="van-badge__wrapper van-icon van-icon-search search-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-search search-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -333,8 +365,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--center">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Cell title
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
@ -109,9 +109,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -121,9 +122,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -138,9 +140,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -157,9 +160,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -169,9 +173,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon">
|
||||
</i>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -219,17 +224,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span class="custom-title">
|
||||
Cell title
|
||||
</span>
|
||||
<transition-stub appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
<transition-stub
|
||||
appear="false"
|
||||
persisted="false"
|
||||
css="true"
|
||||
>
|
||||
<span class="van-tag van-tag--primary">
|
||||
Tag
|
||||
|
@ -1,8 +1,11 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should change arrow direction when using arrow-direction prop 1`] = `
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow-down van-cell__right-icon">
|
||||
</i>
|
||||
"<i class=\\"van-badge__wrapper van-icon van-icon-arrow-down van-cell__right-icon\\">
|
||||
<!---->
|
||||
<!---->
|
||||
<!---->
|
||||
</i>"
|
||||
`;
|
||||
|
||||
exports[`should change icon class prefix when using icon-prefix prop 1`] = `
|
||||
@ -38,8 +41,13 @@ exports[`should render label slot correctly 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render tag prop correctly 1`] = `
|
||||
<a class="van-cell">
|
||||
</a>
|
||||
"<a class=\\"van-cell\\">
|
||||
<!---->
|
||||
<!---->
|
||||
<!---->
|
||||
<!---->
|
||||
<!---->
|
||||
</a>"
|
||||
`;
|
||||
|
||||
exports[`should render title slot correctly 1`] = `
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,20 +1,23 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -27,16 +30,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--disabled"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--disabled"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -46,16 +52,19 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--disabled van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--disabled van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -70,17 +79,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-checkbox-group">
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--square van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--square van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -90,17 +102,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Custom Shape a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--square van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--square van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -114,17 +129,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style="border-color:#ee0a24;background-color:#ee0a24;"
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style="border-color:#ee0a24;background-color:#ee0a24;"
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -137,17 +155,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style="font-size:24px;"
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style="font-size:24px;"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -160,14 +181,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/user-active.png">
|
||||
@ -180,21 +203,24 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<span class="van-checkbox__label van-checkbox__label--left">
|
||||
<!--[-->
|
||||
Left Label
|
||||
</span>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -203,17 +229,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--label-disabled"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--label-disabled"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -228,17 +257,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-checkbox-group">
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -248,17 +280,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -274,17 +309,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-checkbox-group van-checkbox-group--horizontal">
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -294,17 +332,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -320,17 +361,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-checkbox-group">
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -340,17 +384,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -360,17 +407,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox b
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -386,17 +436,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-checkbox-group">
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -406,17 +459,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -426,17 +482,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox b
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -448,9 +507,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="demo-checkbox-buttons">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -459,9 +519,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -479,58 +540,68 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell-group van-cell-group--inset">
|
||||
<!--[-->
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Checkbox b
|
||||
</span>
|
||||
</div>
|
||||
<!--[-->
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round"
|
||||
style
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
|
@ -1,11 +1,12 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -17,9 +18,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--disabled">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -29,9 +31,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--disabled"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--disabled van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -44,10 +47,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-checkbox-group">
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--square van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -57,10 +61,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Custom Shape a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--square van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -73,14 +78,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success"
|
||||
style="border-color: #ee0a24; background-color: rgb(238, 10, 36);"
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-success"
|
||||
style="border-color: #ee0a24; background-color: rgb(238, 10, 36);"
|
||||
>
|
||||
</i>
|
||||
</div>
|
||||
@ -90,13 +97,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style="font-size: 24px;"
|
||||
<div
|
||||
class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"
|
||||
style="font-size: 24px;"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
</i>
|
||||
@ -107,10 +116,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked">
|
||||
<img src="https://fastly.jsdelivr.net/npm/@vant/assets/user-active.png">
|
||||
@ -121,10 +131,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<span class="van-checkbox__label van-checkbox__label--left">
|
||||
Left Label
|
||||
@ -136,10 +147,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--label-disabled"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--label-disabled"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -152,10 +164,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-checkbox-group">
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -165,10 +178,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="true"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -182,10 +196,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-checkbox-group van-checkbox-group--horizontal">
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -195,10 +210,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox van-checkbox--horizontal"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -212,10 +228,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-checkbox-group">
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -225,10 +242,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -238,10 +256,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox b
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -255,10 +274,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-checkbox-group">
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -268,10 +288,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -281,10 +302,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Checkbox b
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -296,8 +318,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="demo-checkbox-buttons">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -305,8 +328,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -319,19 +343,21 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-checkbox-group">
|
||||
<div class="van-cell-group van-cell-group--inset">
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
Checkbox a
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
@ -339,19 +365,21 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--clickable"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
Checkbox b
|
||||
</span>
|
||||
</div>
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<div class="van-checkbox__icon van-checkbox__icon--round">
|
||||
<i class="van-badge__wrapper van-icon van-icon-success">
|
||||
|
@ -1,10 +1,11 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should adjust label position when using label-position prop 1`] = `
|
||||
<div role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="checkbox"
|
||||
class="van-checkbox"
|
||||
tabindex="0"
|
||||
aria-checked="false"
|
||||
>
|
||||
<span class="van-checkbox__label van-checkbox__label--left">
|
||||
Label
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -91,7 +91,7 @@ test('should adjust label position when using label-position prop', () => {
|
||||
});
|
||||
|
||||
test('should emit click event when checkbox icon is clicked', async () => {
|
||||
const onClick = jest.fn();
|
||||
const onClick = vi.fn();
|
||||
const wrapper = mount(Checkbox, {
|
||||
props: {
|
||||
onClick,
|
||||
|
@ -1,23 +1,27 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-circle"
|
||||
style
|
||||
<div
|
||||
class="van-circle"
|
||||
style
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -28,20 +32,24 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-circle"
|
||||
style
|
||||
<div
|
||||
class="van-circle"
|
||||
style
|
||||
>
|
||||
<svg viewbox="0 0 1060 1060"
|
||||
style
|
||||
<svg
|
||||
viewbox="0 0 1060 1060"
|
||||
style
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:60px;"
|
||||
d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:60px;"
|
||||
d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:61px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:61px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -49,21 +57,25 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Custom Width
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style
|
||||
<div
|
||||
class="van-circle"
|
||||
style
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke:#ebedf0;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke:#ebedf0;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke:#ee0a24;stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#ee0a24"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke:#ee0a24;stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#ee0a24"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -71,39 +83,46 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Custom Color
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style
|
||||
<div
|
||||
class="van-circle"
|
||||
style
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style
|
||||
>
|
||||
<defs>
|
||||
<linearGradient id="van-circle-3"
|
||||
x1="100%"
|
||||
y1="0%"
|
||||
x2="0%"
|
||||
y2="0%"
|
||||
<linearGradient
|
||||
id="van-circle-3"
|
||||
x1="100%"
|
||||
y1="0%"
|
||||
x2="0%"
|
||||
y2="0%"
|
||||
>
|
||||
<!--[-->
|
||||
<stop offset="0%"
|
||||
stop-color="#3fecff"
|
||||
<stop
|
||||
offset="0%"
|
||||
stop-color="#3fecff"
|
||||
>
|
||||
</stop>
|
||||
<stop offset="100%"
|
||||
stop-color="#6149f6"
|
||||
<stop
|
||||
offset="100%"
|
||||
stop-color="#6149f6"
|
||||
>
|
||||
</stop>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke:url(#van-circle-3);stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="url(#van-circle-3)"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke:url(#van-circle-3);stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="url(#van-circle-3)"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -111,21 +130,25 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Gradient
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style="margin-top:15px;"
|
||||
<div
|
||||
class="van-circle"
|
||||
style="margin-top:15px;"
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke:#07c160;stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#07c160"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke:#07c160;stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#07c160"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -133,21 +156,25 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Counter Clockwise
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style="width:120px;height:120px;margin-top:15px;"
|
||||
<div
|
||||
class="van-circle"
|
||||
style="width:120px;height:120px;margin-top:15px;"
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke:#7232dd;stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#7232dd"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke:#7232dd;stroke-width:41px;stroke-dasharray:2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#7232dd"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -157,9 +184,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div style="margin-top:15px;">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -167,9 +195,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--small"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--small"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -180,20 +209,24 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-circle"
|
||||
style
|
||||
<div
|
||||
class="van-circle"
|
||||
style
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style="transform:rotate(270deg);"
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style="transform:rotate(270deg);"
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -201,20 +234,24 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Left
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style
|
||||
<div
|
||||
class="van-circle"
|
||||
style
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style="transform:rotate(90deg);"
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style="transform:rotate(90deg);"
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -222,20 +259,24 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Right
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style
|
||||
<div
|
||||
class="van-circle"
|
||||
style
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style="transform:rotate(180deg);"
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style="transform:rotate(180deg);"
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill:none;stroke-width:40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width:41px;stroke-dasharray:2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
|
@ -1,17 +1,19 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1040 1040">
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -23,14 +25,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1060 1060">
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 60px;"
|
||||
d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 60px;"
|
||||
d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 61px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 530 530 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 61px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -40,15 +44,17 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1040 1040">
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke: #ebedf0; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke: #ebedf0; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke: #ee0a24; stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#ee0a24"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke: #ee0a24; stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#ee0a24"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -59,31 +65,36 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1040 1040">
|
||||
<defs>
|
||||
<linearGradient id="van-circle-3"
|
||||
x1="100%"
|
||||
y1="0%"
|
||||
x2="0%"
|
||||
y2="0%"
|
||||
<linearGradient
|
||||
id="van-circle-3"
|
||||
x1="100%"
|
||||
y1="0%"
|
||||
x2="0%"
|
||||
y2="0%"
|
||||
>
|
||||
<stop offset="0%"
|
||||
stop-color="#3fecff"
|
||||
<stop
|
||||
offset="0%"
|
||||
stop-color="#3fecff"
|
||||
>
|
||||
</stop>
|
||||
<stop offset="100%"
|
||||
stop-color="#6149f6"
|
||||
<stop
|
||||
offset="100%"
|
||||
stop-color="#6149f6"
|
||||
>
|
||||
</stop>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke: url(#van-circle-3); stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="url(#van-circle-3)"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke: url(#van-circle-3); stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="url(#van-circle-3)"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -91,19 +102,22 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Gradient
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style="margin-top: 15px;"
|
||||
<div
|
||||
class="van-circle"
|
||||
style="margin-top: 15px;"
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040">
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke: #07c160; stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#07c160"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke: #07c160; stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#07c160"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -111,19 +125,22 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Counter Clockwise
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle"
|
||||
style="width: 120px; height: 120px; margin-top: 15px;"
|
||||
<div
|
||||
class="van-circle"
|
||||
style="width: 120px; height: 120px; margin-top: 15px;"
|
||||
>
|
||||
<svg viewbox="0 0 1040 1040">
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke: #7232dd; stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#7232dd"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 0 0, 1000 a 500, 500 0 1, 0 0, -1000"
|
||||
style="stroke: #7232dd; stroke-width: 41px; stroke-dasharray: 2198px 3140px;"
|
||||
class="van-circle__hover"
|
||||
stroke="#7232dd"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -133,8 +150,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div style="margin-top: 15px;">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--small"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -142,8 +160,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--danger van-button--small"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--danger van-button--small"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -154,17 +173,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style="transform: rotate(270deg);"
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style="transform: rotate(270deg);"
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -173,17 +195,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style="transform: rotate(90deg);"
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style="transform: rotate(90deg);"
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
@ -192,17 +217,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1040 1040"
|
||||
style="transform: rotate(180deg);"
|
||||
<svg
|
||||
viewbox="0 0 1040 1040"
|
||||
style="transform: rotate(180deg);"
|
||||
>
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-dasharray: 2355px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
|
@ -1,16 +1,18 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should change stroke linecap when using stroke-linecap prop 1`] = `
|
||||
<div class="van-circle">
|
||||
<svg viewbox="0 0 1040 1040">
|
||||
<path class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
<path
|
||||
class="van-circle__layer"
|
||||
style="fill: none; stroke-width: 40px;"
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
>
|
||||
</path>
|
||||
<path d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-linecap: square; stroke-dasharray: 0px 3140px;"
|
||||
class="van-circle__hover"
|
||||
<path
|
||||
d="M 520 520 m 0, -500 a 500, 500 0 1, 1 0, 1000 a 500, 500 0 1, 1 0, -1000"
|
||||
style="stroke-width: 41px; stroke-linecap: square; stroke-dasharray: 0px 3140px;"
|
||||
class="van-circle__hover"
|
||||
>
|
||||
</path>
|
||||
</svg>
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
@ -6,20 +6,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-row">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
<!--[-->
|
||||
span: 8
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
<!--[-->
|
||||
span: 8
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
<!--[-->
|
||||
span: 8
|
||||
@ -27,14 +30,16 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-row">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--4"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--4"
|
||||
>
|
||||
<!--[-->
|
||||
span: 4
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--10 van-col--offset-4"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--10 van-col--offset-4"
|
||||
>
|
||||
<!--[-->
|
||||
offset: 4, span: 10
|
||||
@ -42,8 +47,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-row">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--12 van-col--offset-12"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--12 van-col--offset-12"
|
||||
>
|
||||
<!--[-->
|
||||
offset: 12, span: 12
|
||||
@ -54,20 +60,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-row">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
<!--[-->
|
||||
span: 8
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
<!--[-->
|
||||
span: 8
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
<!--[-->
|
||||
span: 8
|
||||
@ -78,20 +87,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div class="van-row van-row--justify-center">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
@ -99,20 +111,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-row van-row--justify-end">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
@ -120,20 +135,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-row van-row--justify-space-between">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
@ -141,20 +159,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div class="van-row van-row--justify-space-around">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
</div>
|
||||
<div style
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
<!--[-->
|
||||
span: 6
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
@ -29,18 +29,21 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-row">
|
||||
<div class="van-col van-col--8"
|
||||
style="padding-right: 13.333333333333334px;"
|
||||
<div
|
||||
class="van-col van-col--8"
|
||||
style="padding-right: 13.333333333333334px;"
|
||||
>
|
||||
span: 8
|
||||
</div>
|
||||
<div style="padding-left: 6.666666666666666px; padding-right: 6.666666666666668px;"
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style="padding-left: 6.666666666666666px; padding-right: 6.666666666666668px;"
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
span: 8
|
||||
</div>
|
||||
<div style="padding-left: 13.333333333333332px;"
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style="padding-left: 13.333333333333332px;"
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
span: 8
|
||||
</div>
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render Col correctly 1`] = `
|
||||
<div class="van-col van-col--8">
|
||||
@ -13,65 +13,75 @@ exports[`should render gutter correctly 1`] = `
|
||||
<div class="van-col van-col--12">
|
||||
12
|
||||
</div>
|
||||
<div style="padding-left: 12px;"
|
||||
class="van-col van-col--12"
|
||||
<div
|
||||
style="padding-left: 12px;"
|
||||
class="van-col van-col--12"
|
||||
>
|
||||
12
|
||||
</div>
|
||||
<div class="van-col van-col--8">
|
||||
8
|
||||
</div>
|
||||
<div style="padding-left: 12px;"
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style="padding-left: 12px;"
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
8
|
||||
</div>
|
||||
<div style="padding-left: 16px;"
|
||||
class="van-col van-col--8"
|
||||
<div
|
||||
style="padding-left: 16px;"
|
||||
class="van-col van-col--8"
|
||||
>
|
||||
8
|
||||
</div>
|
||||
<div class="van-col van-col--6">
|
||||
6
|
||||
</div>
|
||||
<div style="padding-left: 12px;"
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style="padding-left: 12px;"
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
6
|
||||
</div>
|
||||
<div style="padding-left: 16px;"
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style="padding-left: 16px;"
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
6
|
||||
</div>
|
||||
<div style="padding-left: 18px;"
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style="padding-left: 18px;"
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
6
|
||||
</div>
|
||||
<div class="van-col van-col--7">
|
||||
7
|
||||
</div>
|
||||
<div style="padding-left: 12px;"
|
||||
class="van-col van-col--6"
|
||||
<div
|
||||
style="padding-left: 12px;"
|
||||
class="van-col van-col--6"
|
||||
>
|
||||
6
|
||||
</div>
|
||||
<div style="padding-left: 16px;"
|
||||
class="van-col van-col--5"
|
||||
<div
|
||||
style="padding-left: 16px;"
|
||||
class="van-col van-col--5"
|
||||
>
|
||||
5
|
||||
</div>
|
||||
<div style="padding-left: 18px;"
|
||||
class="van-col van-col--4"
|
||||
<div
|
||||
style="padding-left: 18px;"
|
||||
class="van-col van-col--4"
|
||||
>
|
||||
4
|
||||
</div>
|
||||
<div class="van-col van-col--3">
|
||||
3
|
||||
</div>
|
||||
<div style="padding-left: 12px;"
|
||||
class="van-col van-col--2"
|
||||
<div
|
||||
style="padding-left: 12px;"
|
||||
class="van-col van-col--2"
|
||||
>
|
||||
2
|
||||
</div>
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
@ -7,20 +7,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title1
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -33,40 +36,46 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title2
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title3
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -79,20 +88,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title1
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -105,40 +117,46 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title2
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title3
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -151,58 +169,67 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title1
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title2
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title3
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -215,42 +242,49 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
Title1
|
||||
<i class="van-badge__wrapper van-icon van-icon-question-o"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-question-o"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-shop-o van-cell__left-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-shop-o van-cell__left-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title2
|
||||
@ -261,8 +295,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Content
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -275,20 +310,23 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<!--[-->
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title1
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -301,40 +339,46 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title2
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Title3
|
||||
</span>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -342,9 +386,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="demo-collapse-buttons">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -353,9 +398,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,13 +1,14 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -24,10 +25,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -39,10 +41,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -58,10 +61,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -78,10 +82,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -93,10 +98,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -112,10 +118,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -127,9 +134,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -141,9 +149,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-collapse-item__title van-collapse-item__title--disabled"
|
||||
role="button"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -159,10 +168,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
Title1
|
||||
@ -174,10 +184,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-shop-o van-cell__left-icon">
|
||||
</i>
|
||||
@ -200,10 +211,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title van-collapse-item__title--expanded"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="true"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -220,10 +232,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -235,10 +248,11 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-collapse-item van-collapse-item--border">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<div class="van-cell__title">
|
||||
<span>
|
||||
@ -251,8 +265,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="demo-collapse-buttons">
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -260,8 +275,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</span>
|
||||
</div>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
<button
|
||||
type="button"
|
||||
class="van-button van-button--primary van-button--normal"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,12 +1,13 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render slots of CollapseItem correctly 1`] = `
|
||||
<div class="van-collapse van-hairline--top-bottom">
|
||||
<div class="van-collapse-item">
|
||||
<div class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
<div
|
||||
class="van-cell van-cell--clickable van-collapse-item__title"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
>
|
||||
this is icon
|
||||
<div class="van-cell__title">
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -6,7 +6,7 @@ export function useId() {
|
||||
const vm = getCurrentInstance();
|
||||
const { name = 'unknown' } = vm?.type || {};
|
||||
|
||||
// keep jest snapshot stable
|
||||
// keep test snapshot stable
|
||||
if (process.env.NODE_ENV === 'test') {
|
||||
return name;
|
||||
}
|
||||
|
@ -1,12 +1,13 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div style="min-height:100vh;">
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell">
|
||||
<div class="van-cell__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title"
|
||||
style
|
||||
>
|
||||
<span>
|
||||
Please click the button in the upper right corner to switch between dark and light modes.
|
||||
@ -19,12 +20,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<form class="van-form">
|
||||
<!--[-->
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
style
|
||||
>
|
||||
Rate
|
||||
</label>
|
||||
@ -34,79 +37,90 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<!--[-->
|
||||
<div role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
<div
|
||||
role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star-o van-rate__icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star-o van-rate__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -117,12 +131,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
style
|
||||
>
|
||||
Slider
|
||||
</label>
|
||||
@ -132,22 +148,26 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-slider"
|
||||
<div
|
||||
style
|
||||
class="van-slider"
|
||||
>
|
||||
<div class="van-slider__bar"
|
||||
style="width:50%;left:0%;"
|
||||
<div
|
||||
class="van-slider__bar"
|
||||
style="width:50%;left:0%;"
|
||||
>
|
||||
<div role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
<div
|
||||
role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
>
|
||||
<div class="van-slider__button"
|
||||
style
|
||||
<div
|
||||
class="van-slider__button"
|
||||
style
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -158,9 +178,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div style="margin:16px;">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
style
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -174,19 +195,22 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-config-provider"
|
||||
style="--van-rate-icon-full-color:#07c160;--van-slider-bar-height:4px;--van-slider-button-width:20px;--van-slider-button-height:20px;--van-slider-active-background:#07c160;--van-button-primary-background:#07c160;--van-button-primary-border-color:#07c160;"
|
||||
<div
|
||||
class="van-config-provider"
|
||||
style="--van-rate-icon-full-color:#07c160;--van-slider-bar-height:4px;--van-slider-button-width:20px;--van-slider-button-height:20px;--van-slider-active-background:#07c160;--van-button-primary-background:#07c160;--van-button-primary-border-color:#07c160;"
|
||||
>
|
||||
<!--[-->
|
||||
<form class="van-form">
|
||||
<!--[-->
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
style
|
||||
>
|
||||
Rate
|
||||
</label>
|
||||
@ -196,79 +220,90 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<!--[-->
|
||||
<div role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
<div
|
||||
role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
>
|
||||
<!--[-->
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="radio"
|
||||
style
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star-o van-rate__icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-star-o van-rate__icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -279,12 +314,14 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div class="van-cell van-field">
|
||||
<div class="van-cell__title van-field__label"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-field__label"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<label id="van-field-label"
|
||||
style
|
||||
<label
|
||||
id="van-field-label"
|
||||
style
|
||||
>
|
||||
Slider
|
||||
</label>
|
||||
@ -294,22 +331,26 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<!--[-->
|
||||
<div style
|
||||
class="van-slider"
|
||||
<div
|
||||
style
|
||||
class="van-slider"
|
||||
>
|
||||
<div class="van-slider__bar"
|
||||
style="width:50%;left:0%;"
|
||||
<div
|
||||
class="van-slider__bar"
|
||||
style="width:50%;left:0%;"
|
||||
>
|
||||
<div role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
<div
|
||||
role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
>
|
||||
<div class="van-slider__button"
|
||||
style
|
||||
<div
|
||||
class="van-slider__button"
|
||||
style
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@ -320,9 +361,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div style="margin:16px;">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
style
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
style
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div style="min-height: 100vh;">
|
||||
@ -22,58 +22,64 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<div role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
<div
|
||||
role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star-o van-rate__icon">
|
||||
</i>
|
||||
@ -93,16 +99,18 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<div class="van-slider">
|
||||
<div class="van-slider__bar"
|
||||
style="width: 50%; left: 0%;"
|
||||
<div
|
||||
class="van-slider__bar"
|
||||
style="width: 50%; left: 0%;"
|
||||
>
|
||||
<div role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
<div
|
||||
role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
>
|
||||
<div class="van-slider__button">
|
||||
</div>
|
||||
@ -114,8 +122,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div style="margin: 16px;">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
@ -127,8 +136,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</form>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-config-provider"
|
||||
style="--van-rate-icon-full-color: #07c160; --van-slider-bar-height: 4px; --van-slider-button-width: 20px; --van-slider-button-height: 20px; --van-slider-active-background: #07c160; --van-button-primary-background: #07c160; --van-button-primary-border-color: #07c160;"
|
||||
<div
|
||||
class="van-config-provider"
|
||||
style="--van-rate-icon-full-color: #07c160; --van-slider-bar-height: 4px; --van-slider-button-width: 20px; --van-slider-button-height: 20px; --van-slider-active-background: #07c160; --van-button-primary-background: #07c160; --van-button-primary-border-color: #07c160;"
|
||||
>
|
||||
<form class="van-form">
|
||||
<div class="van-cell van-field">
|
||||
@ -140,58 +150,64 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-cell__value van-field__value">
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<div role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
<div
|
||||
role="radiogroup"
|
||||
class="van-rate"
|
||||
tabindex="0"
|
||||
aria-disabled="false"
|
||||
aria-readonly="false"
|
||||
>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="1"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="2"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="3"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="4"
|
||||
aria-checked="true"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star van-rate__icon van-rate__icon--full">
|
||||
</i>
|
||||
</div>
|
||||
<div role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
<div
|
||||
role="radio"
|
||||
class="van-rate__item"
|
||||
tabindex="0"
|
||||
aria-setsize="5"
|
||||
aria-posinset="5"
|
||||
aria-checked="false"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-star-o van-rate__icon">
|
||||
</i>
|
||||
@ -211,16 +227,18 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div class="van-field__body">
|
||||
<div class="van-field__control van-field__control--custom">
|
||||
<div class="van-slider">
|
||||
<div class="van-slider__bar"
|
||||
style="width: 50%; left: 0%;"
|
||||
<div
|
||||
class="van-slider__bar"
|
||||
style="width: 50%; left: 0%;"
|
||||
>
|
||||
<div role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
<div
|
||||
role="slider"
|
||||
class="van-slider__button-wrapper van-slider__button-wrapper--right"
|
||||
tabindex="0"
|
||||
aria-valuemin="0"
|
||||
aria-valuenow="50"
|
||||
aria-valuemax="100"
|
||||
aria-orientation="horizontal"
|
||||
>
|
||||
<div class="van-slider__button">
|
||||
</div>
|
||||
@ -232,8 +250,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div style="margin: 16px;">
|
||||
<button type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
<button
|
||||
type="submit"
|
||||
class="van-button van-button--primary van-button--normal van-button--block van-button--round"
|
||||
>
|
||||
<div class="van-button__content">
|
||||
<span class="van-button__text">
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should change icon class-prefix when using icon-prefix prop 1`] = `
|
||||
<div class="van-config-provider">
|
||||
@ -8,6 +8,7 @@ exports[`should change icon class-prefix when using icon-prefix prop 1`] = `
|
||||
`;
|
||||
|
||||
exports[`should render tag prop correctly 1`] = `
|
||||
<section class="van-config-provider">
|
||||
</section>
|
||||
"<section class=\\"van-config-provider\\">
|
||||
<!---->
|
||||
</section>"
|
||||
`;
|
||||
|
@ -1,5 +1,5 @@
|
||||
/**
|
||||
* @jest-environment node
|
||||
* @vitest-environment node
|
||||
*/
|
||||
import Demo from '../demo/index.vue';
|
||||
import { snapshotDemo } from '../../../test/demo';
|
||||
|
@ -1,26 +1,30 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<!--[-->
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--add"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--add"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-add-square van-cell__left-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-add-square van-cell__left-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
<div class="van-cell__title van-contact-card__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-contact-card__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
Add contact
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -28,17 +32,20 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--edit"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--edit"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-contact van-cell__left-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-contact van-cell__left-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
<div class="van-cell__title van-contact-card__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-contact-card__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div>
|
||||
@ -48,8 +55,9 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
Phone:13000000000
|
||||
</div>
|
||||
</div>
|
||||
<i class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-arrow van-cell__right-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
@ -58,13 +66,15 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<!--[-->
|
||||
<div class="van-cell van-cell--center van-cell--borderless van-contact-card van-contact-card--edit">
|
||||
<i class="van-badge__wrapper van-icon van-icon-contact van-cell__left-icon"
|
||||
style
|
||||
<i
|
||||
class="van-badge__wrapper van-icon van-icon-contact van-cell__left-icon"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
</i>
|
||||
<div class="van-cell__title van-contact-card__title"
|
||||
style
|
||||
<div
|
||||
class="van-cell__title van-contact-card__title"
|
||||
style
|
||||
>
|
||||
<!--[-->
|
||||
<div>
|
||||
|
@ -1,10 +1,11 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
|
||||
|
||||
exports[`should render demo and match snapshot 1`] = `
|
||||
<div>
|
||||
<div class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--add"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--add"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-add-square van-cell__left-icon">
|
||||
</i>
|
||||
@ -16,9 +17,10 @@ exports[`should render demo and match snapshot 1`] = `
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--edit"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
<div
|
||||
class="van-cell van-cell--center van-cell--clickable van-cell--borderless van-contact-card van-contact-card--edit"
|
||||
role="button"
|
||||
tabindex="0"
|
||||
>
|
||||
<i class="van-badge__wrapper van-icon van-icon-contact van-cell__left-icon">
|
||||
</i>
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user