Skip to content

Commit

Permalink
feat: New Component Watermark (#39064)
Browse files Browse the repository at this point in the history
* feat: New Component Watermark

* docs: add watermark docs

* docs: add watermark demo

* test: add watermark test

* test: add watermark snapshot

* chore: add jest-canvas-mock

* feat: Watermark calculates the width and height of content by default

* docs: update docs

* docs: update demo

* test: update snapshot

* docs: update docs

* chore: update bundlesize

* chore: Optimize code logic

* chore: update size-limit

* test: update watermark snapshot
  • Loading branch information
JarvisArt committed Dec 8, 2022
1 parent 451d2f6 commit 6f83c63
Show file tree
Hide file tree
Showing 24 changed files with 2,860 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .jest.js
Expand Up @@ -34,7 +34,7 @@ function getTestRegex(libDir) {
module.exports = {
verbose: true,
testEnvironment: 'jsdom',
setupFiles: ['./tests/setup.js'],
setupFiles: ['./tests/setup.js', 'jest-canvas-mock'],
setupFilesAfterEnv: ['./tests/setupAfterEnv.ts'],
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'md'],
modulePathIgnorePatterns: ['/_site/'],
Expand Down
1 change: 1 addition & 0 deletions components/__tests__/__snapshots__/index.test.ts.snap
Expand Up @@ -67,6 +67,7 @@ exports[`antd exports modules correctly 1`] = `
"TreeSelect",
"Typography",
"Upload",
"Watermark",
"message",
"notification",
"theme",
Expand Down
2 changes: 2 additions & 0 deletions components/index.tsx
Expand Up @@ -150,6 +150,8 @@ export { default as Typography } from './typography';
export type { TypographyProps } from './typography';
export { default as Upload } from './upload';
export type { UploadFile, UploadProps } from './upload';
export { default as Watermark } from './watermark';
export type { WatermarkProps } from './watermark';
export { default as QRCode } from './qrcode';
export type { QRCodeProps, QRPropsCanvas } from './qrcode/interface';
export { default as version } from './version';
1,290 changes: 1,290 additions & 0 deletions components/watermark/__tests__/__snapshots__/demo-extend.test.ts.snap

Large diffs are not rendered by default.

0 comments on commit 6f83c63

Please sign in to comment.