mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-05 05:28:20 +08:00
d3c2f75ed3
* refactor: Modal confirm style * test: fix test case * chore: merge wireframe * chore: modify limit * test: update snapshot
1215 lines
29 KiB
Plaintext
1215 lines
29 KiB
Plaintext
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
|
|
exports[`renders components/modal/demo/async.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal with async logic
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/basic.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/button-props.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal with customized button props
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/component-token.tsx correctly 1`] = `
|
|
<div
|
|
style="display:flex;flex-direction:column;row-gap:16px"
|
|
>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel"
|
|
role="dialog"
|
|
style="width:100%;height:200px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<button
|
|
aria-label="Close"
|
|
class="ant-modal-close"
|
|
type="button"
|
|
>
|
|
<span
|
|
class="ant-modal-close-x"
|
|
>
|
|
<span
|
|
aria-label="close"
|
|
class="anticon anticon-close ant-modal-close-icon"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="close"
|
|
fill="currentColor"
|
|
fill-rule="evenodd"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
</span>
|
|
</button>
|
|
<div
|
|
class="ant-modal-header"
|
|
>
|
|
<div
|
|
class="ant-modal-title"
|
|
>
|
|
Hello World!
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
Hello World?!
|
|
</div>
|
|
<div
|
|
class="ant-modal-footer"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Cancel
|
|
</span>
|
|
</button>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel"
|
|
role="dialog"
|
|
style="width:100%;height:200px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<button
|
|
aria-label="Close"
|
|
class="ant-modal-close"
|
|
type="button"
|
|
>
|
|
<span
|
|
class="ant-modal-close-x"
|
|
>
|
|
<span
|
|
aria-label="close"
|
|
class="anticon anticon-close ant-modal-close-icon"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="close"
|
|
fill="currentColor"
|
|
fill-rule="evenodd"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
</span>
|
|
</button>
|
|
<div
|
|
class="ant-modal-header"
|
|
>
|
|
<div
|
|
class="ant-modal-title"
|
|
>
|
|
Hello World!
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
Hello World?!
|
|
</div>
|
|
<div
|
|
class="ant-modal-footer"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Cancel
|
|
</span>
|
|
</button>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel ant-modal-confirm ant-modal-confirm-success"
|
|
role="dialog"
|
|
style="width:200px;height:150px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body-wrapper"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body"
|
|
>
|
|
<span
|
|
aria-label="check-circle"
|
|
class="anticon anticon-check-circle"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="check-circle"
|
|
fill="currentColor"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-paragraph"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-content"
|
|
>
|
|
A good news!
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-confirm-btns"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel ant-modal-confirm ant-modal-confirm-confirm"
|
|
role="dialog"
|
|
style="width:300px;height:200px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body-wrapper"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body ant-modal-confirm-body-has-title"
|
|
>
|
|
<span
|
|
aria-label="exclamation-circle"
|
|
class="anticon anticon-exclamation-circle"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="exclamation-circle"
|
|
fill="currentColor"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-paragraph"
|
|
>
|
|
<span
|
|
class="ant-modal-confirm-title"
|
|
>
|
|
Confirm This?
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-content"
|
|
>
|
|
Some descriptions.
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-confirm-btns"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Cancel
|
|
</span>
|
|
</button>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
</div>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/confirm.tsx correctly 1`] = `
|
|
<div
|
|
class="ant-space ant-space-horizontal ant-space-align-center"
|
|
style="flex-wrap:wrap;margin-bottom:-8px"
|
|
>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px;padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Confirm
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px;padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
With promise
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px;padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-dashed"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Delete
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-dashed"
|
|
type="button"
|
|
>
|
|
<span>
|
|
With extra props
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/confirm-router.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Confirm
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/custom-mouse-position.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/dark.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/footer.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal with customized footer
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/footer-render.tsx correctly 1`] = `
|
|
<div
|
|
class="ant-space ant-space-horizontal ant-space-align-center"
|
|
>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal Confirm
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/hooks.tsx correctly 1`] = `
|
|
<div
|
|
class="ant-space ant-space-horizontal ant-space-align-center"
|
|
>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Confirm
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Warning
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Info
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Error
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/locale.tsx correctly 1`] = `
|
|
<div
|
|
class="ant-space ant-space-horizontal ant-space-align-center"
|
|
>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Modal
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Confirm
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/manual.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open modal to close in 5s
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/modal-render.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Draggable Modal
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/position.tsx correctly 1`] = `
|
|
Array [
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Display a modal dialog at 20px to Top
|
|
</span>
|
|
</button>,
|
|
<br />,
|
|
<br />,
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Vertically centered modal dialog
|
|
</span>
|
|
</button>,
|
|
]
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/render-panel.tsx correctly 1`] = `
|
|
<div
|
|
style="display:flex;flex-direction:column;row-gap:16px"
|
|
>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel"
|
|
role="dialog"
|
|
style="width:100%;height:200px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<button
|
|
aria-label="Close"
|
|
class="ant-modal-close"
|
|
type="button"
|
|
>
|
|
<span
|
|
class="ant-modal-close-x"
|
|
>
|
|
<span
|
|
aria-label="close"
|
|
class="anticon anticon-close ant-modal-close-icon"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="close"
|
|
fill="currentColor"
|
|
fill-rule="evenodd"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
</span>
|
|
</button>
|
|
<div
|
|
class="ant-modal-header"
|
|
>
|
|
<div
|
|
class="ant-modal-title"
|
|
>
|
|
Hello World!
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
Hello World?!
|
|
</div>
|
|
<div
|
|
class="ant-modal-footer"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Cancel
|
|
</span>
|
|
</button>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel ant-modal-confirm ant-modal-confirm-success"
|
|
role="dialog"
|
|
style="width:200px;height:150px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body-wrapper"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body"
|
|
>
|
|
<span
|
|
aria-label="check-circle"
|
|
class="anticon anticon-check-circle"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="check-circle"
|
|
fill="currentColor"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-paragraph"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-content"
|
|
>
|
|
A good news!
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-confirm-btns"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel ant-modal-confirm ant-modal-confirm-confirm"
|
|
role="dialog"
|
|
style="width:300px;height:200px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body-wrapper"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body ant-modal-confirm-body-has-title"
|
|
>
|
|
<span
|
|
aria-label="exclamation-circle"
|
|
class="anticon anticon-exclamation-circle"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="exclamation-circle"
|
|
fill="currentColor"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-paragraph"
|
|
>
|
|
<span
|
|
class="ant-modal-confirm-title"
|
|
>
|
|
Confirm This?
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-content"
|
|
>
|
|
Some descriptions.
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-confirm-btns"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Cancel
|
|
</span>
|
|
</button>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
</div>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/static-info.tsx correctly 1`] = `
|
|
<div
|
|
class="ant-space ant-space-horizontal ant-space-align-center"
|
|
style="flex-wrap:wrap;margin-bottom:-8px"
|
|
>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px;padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Info
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px;padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Success
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="margin-right:8px;padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Error
|
|
</span>
|
|
</button>
|
|
</div>
|
|
<div
|
|
class="ant-space-item"
|
|
style="padding-bottom:8px"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Warning
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/width.tsx correctly 1`] = `
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Open Modal of 1000px width
|
|
</span>
|
|
</button>
|
|
`;
|
|
|
|
exports[`renders components/modal/demo/wireframe.tsx correctly 1`] = `
|
|
<div
|
|
style="display:flex;flex-direction:column;row-gap:16px"
|
|
>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel"
|
|
role="dialog"
|
|
style="width:100%;height:200px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<button
|
|
aria-label="Close"
|
|
class="ant-modal-close"
|
|
type="button"
|
|
>
|
|
<span
|
|
class="ant-modal-close-x"
|
|
>
|
|
<span
|
|
aria-label="close"
|
|
class="anticon anticon-close ant-modal-close-icon"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="close"
|
|
fill="currentColor"
|
|
fill-rule="evenodd"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
</span>
|
|
</button>
|
|
<div
|
|
class="ant-modal-header"
|
|
>
|
|
<div
|
|
class="ant-modal-title"
|
|
>
|
|
Hello World!
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
Hello World?!
|
|
</div>
|
|
<div
|
|
class="ant-modal-footer"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Cancel
|
|
</span>
|
|
</button>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel ant-modal-confirm ant-modal-confirm-success"
|
|
role="dialog"
|
|
style="width:200px;height:150px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body-wrapper"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body"
|
|
>
|
|
<span
|
|
aria-label="check-circle"
|
|
class="anticon anticon-check-circle"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="check-circle"
|
|
fill="currentColor"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-paragraph"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-content"
|
|
>
|
|
A good news!
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-confirm-btns"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
<div
|
|
aria-modal="true"
|
|
class="ant-modal ant-modal-pure-panel ant-modal-confirm ant-modal-confirm-confirm"
|
|
role="dialog"
|
|
style="width:300px;height:200px"
|
|
>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
<div
|
|
class="ant-modal-content"
|
|
>
|
|
<div
|
|
class="ant-modal-body"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body-wrapper"
|
|
>
|
|
<div
|
|
class="ant-modal-confirm-body ant-modal-confirm-body-has-title"
|
|
>
|
|
<span
|
|
aria-label="exclamation-circle"
|
|
class="anticon anticon-exclamation-circle"
|
|
role="img"
|
|
>
|
|
<svg
|
|
aria-hidden="true"
|
|
data-icon="exclamation-circle"
|
|
fill="currentColor"
|
|
focusable="false"
|
|
height="1em"
|
|
viewBox="64 64 896 896"
|
|
width="1em"
|
|
>
|
|
<path
|
|
d="M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"
|
|
/>
|
|
</svg>
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-paragraph"
|
|
>
|
|
<span
|
|
class="ant-modal-confirm-title"
|
|
>
|
|
Confirm This?
|
|
</span>
|
|
<div
|
|
class="ant-modal-confirm-content"
|
|
>
|
|
Some descriptions.
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
class="ant-modal-confirm-btns"
|
|
>
|
|
<button
|
|
class="ant-btn ant-btn-default"
|
|
type="button"
|
|
>
|
|
<span>
|
|
Cancel
|
|
</span>
|
|
</button>
|
|
<button
|
|
class="ant-btn ant-btn-primary"
|
|
type="button"
|
|
>
|
|
<span>
|
|
OK
|
|
</span>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div
|
|
aria-hidden="true"
|
|
style="width:0;height:0;overflow:hidden;outline:none"
|
|
tabindex="0"
|
|
/>
|
|
</div>
|
|
</div>
|
|
`;
|