Skip to content

Commit

Permalink
chore: update snapshot
Browse files Browse the repository at this point in the history
  • Loading branch information
uyarn committed Dec 28, 2023
1 parent 2dd8abc commit 91ebade
Show file tree
Hide file tree
Showing 3 changed files with 224 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/date-picker/hooks/useTableData.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export interface TableDataProps extends SinglePanelProps {
hoverEnd?: Date | undefined;
minDate: Date | null;
maxDate: Date | null;
cancelRangeSelectLimit: boolean;
cancelRangeSelectLimit?: boolean;
}

export default function useTableData(props: TableDataProps) {
Expand Down
221 changes: 221 additions & 0 deletions test/snap/__snapshots__/csr.test.jsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -70026,6 +70026,227 @@ exports[`csr snapshot test > csr test src/date-picker/_example/base.jsx 1`] = `
}
`;

exports[`csr snapshot test > csr test src/date-picker/_example/cancel-range-limit.jsx 1`] = `
{
"asFragment": [Function],
"baseElement": <body>
<script
class="t-svg-js-stylesheet--unique-class"
src="https://tdesign.gtimg.com/icon/0.2.0/fonts/index.js"
/>
<div>
<div
class="t-space t-space-vertical"
style="gap: 16px;"
>
<div
class="t-space-item"
>
<div
class="t-date-range-picker"
>
<div
class="t-range-input-popup t-range-input-popup"
>
<div
class="t-range-input t-is-default t-range-input--suffix"
value=""
>
<div
class="t-range-input__inner"
>
<div
class="t-input__wrap t-range-input__inner-left"
>
<div
class="t-input t-is-readonly t-align-left"
>
<input
class="t-input__inner"
placeholder="select date"
readonly=""
type="text"
value=""
/>
</div>
</div>
<div
class="t-range-input__inner-separator"
>
~
</div>
<div
class="t-input__wrap t-range-input__inner-right"
>
<div
class="t-input t-is-readonly t-align-left"
>
<input
class="t-input__inner"
placeholder="select date"
readonly=""
type="text"
value=""
/>
</div>
</div>
<span
class="t-range-input__suffix t-range-input__suffix-icon"
>
<svg
class="t-icon t-icon-calendar"
fill="none"
height="1em"
viewBox="0 0 24 24"
width="1em"
>
<path
d="M6 4V1.5h2V4h8V1.5h2V4h4v18H2V4h4zM4 6v3h16V6H4zm16 5H4v9h16v-9z"
fill="currentColor"
/>
</svg>
</span>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>,
"container": <div>
<div
class="t-space t-space-vertical"
style="gap: 16px;"
>
<div
class="t-space-item"
>
<div
class="t-date-range-picker"
>
<div
class="t-range-input-popup t-range-input-popup"
>
<div
class="t-range-input t-is-default t-range-input--suffix"
value=""
>
<div
class="t-range-input__inner"
>
<div
class="t-input__wrap t-range-input__inner-left"
>
<div
class="t-input t-is-readonly t-align-left"
>
<input
class="t-input__inner"
placeholder="select date"
readonly=""
type="text"
value=""
/>
</div>
</div>
<div
class="t-range-input__inner-separator"
>
~
</div>
<div
class="t-input__wrap t-range-input__inner-right"
>
<div
class="t-input t-is-readonly t-align-left"
>
<input
class="t-input__inner"
placeholder="select date"
readonly=""
type="text"
value=""
/>
</div>
</div>
<span
class="t-range-input__suffix t-range-input__suffix-icon"
>
<svg
class="t-icon t-icon-calendar"
fill="none"
height="1em"
viewBox="0 0 24 24"
width="1em"
>
<path
d="M6 4V1.5h2V4h8V1.5h2V4h4v18H2V4h4zM4 6v3h16V6H4zm16 5H4v9h16v-9z"
fill="currentColor"
/>
</svg>
</span>
</div>
</div>
</div>
</div>
</div>
</div>
</div>,
"debug": [Function],
"findAllByAltText": [Function],
"findAllByDisplayValue": [Function],
"findAllByLabelText": [Function],
"findAllByPlaceholderText": [Function],
"findAllByRole": [Function],
"findAllByTestId": [Function],
"findAllByText": [Function],
"findAllByTitle": [Function],
"findByAltText": [Function],
"findByDisplayValue": [Function],
"findByLabelText": [Function],
"findByPlaceholderText": [Function],
"findByRole": [Function],
"findByTestId": [Function],
"findByText": [Function],
"findByTitle": [Function],
"getAllByAltText": [Function],
"getAllByDisplayValue": [Function],
"getAllByLabelText": [Function],
"getAllByPlaceholderText": [Function],
"getAllByRole": [Function],
"getAllByTestId": [Function],
"getAllByText": [Function],
"getAllByTitle": [Function],
"getByAltText": [Function],
"getByDisplayValue": [Function],
"getByLabelText": [Function],
"getByPlaceholderText": [Function],
"getByRole": [Function],
"getByTestId": [Function],
"getByText": [Function],
"getByTitle": [Function],
"queryAllByAltText": [Function],
"queryAllByDisplayValue": [Function],
"queryAllByLabelText": [Function],
"queryAllByPlaceholderText": [Function],
"queryAllByRole": [Function],
"queryAllByTestId": [Function],
"queryAllByText": [Function],
"queryAllByTitle": [Function],
"queryByAltText": [Function],
"queryByDisplayValue": [Function],
"queryByLabelText": [Function],
"queryByPlaceholderText": [Function],
"queryByRole": [Function],
"queryByTestId": [Function],
"queryByText": [Function],
"queryByTitle": [Function],
"rerender": [Function],
"unmount": [Function],
}
`;

exports[`csr snapshot test > csr test src/date-picker/_example/custom-icon.jsx 1`] = `
{
"asFragment": [Function],
Expand Down
2 changes: 2 additions & 0 deletions test/snap/__snapshots__/ssr.test.jsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,8 @@ exports[`ssr snapshot test > ssr test src/config-provider/_example/table.jsx 1`]

exports[`ssr snapshot test > ssr test src/date-picker/_example/base.jsx 1`] = `"<div style=\\"gap:16px\\" class=\\"t-space t-space-vertical\\"><div class=\\"t-space-item\\"><div class=\\"t-date-picker\\"><div class=\\"t-select-input t-select-input--empty\\"><div class=\\"t-input__wrap\\" value=\\"\\"><div class=\\"t-input t-is-readonly t-align-left t-input--prefix t-input--suffix\\"><div class=\\"t-input__prefix\\"></div><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"\\"/><span class=\\"t-input__suffix t-input__suffix-icon\\"><svg fill=\\"none\\" viewBox=\\"0 0 24 24\\" width=\\"1em\\" height=\\"1em\\" class=\\"t-icon t-icon-calendar\\"><path fill=\\"currentColor\\" d=\\"M6 4V1.5h2V4h8V1.5h2V4h4v18H2V4h4zM4 6v3h16V6H4zm16 5H4v9h16v-9z\\"></path></svg></span></div></div></div></div></div><div class=\\"t-space-item\\"><div class=\\"t-date-picker\\"><div class=\\"t-select-input t-select-input--empty\\"><div class=\\"t-input__wrap\\" value=\\"\\"><div class=\\"t-input t-align-left t-input--prefix t-input--suffix\\"><div class=\\"t-input__prefix\\"></div><input placeholder=\\"可清除、可输入的日期选择器\\" type=\\"text\\" class=\\"t-input__inner\\" value=\\"\\"/><span class=\\"t-input__suffix t-input__suffix-icon\\"><svg fill=\\"none\\" viewBox=\\"0 0 24 24\\" width=\\"1em\\" height=\\"1em\\" class=\\"t-icon t-icon-calendar\\"><path fill=\\"currentColor\\" d=\\"M6 4V1.5h2V4h8V1.5h2V4h4v18H2V4h4zM4 6v3h16V6H4zm16 5H4v9h16v-9z\\"></path></svg></span></div></div></div></div></div></div>"`;

exports[`ssr snapshot test > ssr test src/date-picker/_example/cancel-range-limit.jsx 1`] = `"<div style=\\"gap:16px\\" class=\\"t-space t-space-vertical\\"><div class=\\"t-space-item\\"><div class=\\"t-date-range-picker\\"><div class=\\"t-range-input-popup t-range-input-popup\\"><div class=\\"t-range-input t-is-default t-range-input--suffix\\" value=\\"\\"><div class=\\"t-range-input__inner\\"><div class=\\"t-input__wrap t-range-input__inner-left\\"><div class=\\"t-input t-is-readonly t-align-left\\"><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"\\"/></div></div><div class=\\"t-range-input__inner-separator\\"> ~ </div><div class=\\"t-input__wrap t-range-input__inner-right\\"><div class=\\"t-input t-is-readonly t-align-left\\"><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"\\"/></div></div><span class=\\"t-range-input__suffix t-range-input__suffix-icon\\"><svg fill=\\"none\\" viewBox=\\"0 0 24 24\\" width=\\"1em\\" height=\\"1em\\" class=\\"t-icon t-icon-calendar\\"><path fill=\\"currentColor\\" d=\\"M6 4V1.5h2V4h8V1.5h2V4h4v18H2V4h4zM4 6v3h16V6H4zm16 5H4v9h16v-9z\\"></path></svg></span></div></div></div></div></div></div>"`;

exports[`ssr snapshot test > ssr test src/date-picker/_example/custom-icon.jsx 1`] = `"<div style=\\"gap:16px\\" class=\\"t-space t-space-horizontal\\"><div class=\\"t-space-item\\"><div class=\\"t-date-picker\\"><div class=\\"t-select-input t-select-input--empty\\"><div class=\\"t-input__wrap\\" value=\\"\\"><div class=\\"t-input t-is-readonly t-align-left t-input--prefix t-input--suffix\\"><span class=\\"t-input__prefix t-input__prefix-icon\\"><svg fill=\\"none\\" viewBox=\\"0 0 24 24\\" width=\\"1em\\" height=\\"1em\\" class=\\"t-icon t-icon-browse\\"><g clip-path=\\"url(#clip0_8726_7319)\\"><path fill=\\"currentColor\\" d=\\"M2.1 12a10.5 10.5 0 0019.8 0 10.5 10.5 0 00-19.8 0zm-2.01-.3a12.5 12.5 0 0123.82 0l.1.3-.1.3a12.5 12.5 0 01-23.82 0l-.1-.3.1-.3zM12 9a3 3 0 100 6 3 3 0 000-6zm-5 3a5 5 0 1110 0 5 5 0 01-10 0z\\"></path></g></svg></span><div class=\\"t-input__prefix\\"></div><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"\\"/><span class=\\"t-input__suffix t-input__suffix-icon\\"><svg fill=\\"none\\" viewBox=\\"0 0 24 24\\" width=\\"1em\\" height=\\"1em\\" class=\\"t-icon t-icon-lock-on\\"><path fill=\\"currentColor\\" d=\\"M5.5 7.5a6.5 6.5 0 0113 0V9h2v13h-17V9h2V7.5zm2 1.5h9V7.5a4.5 4.5 0 10-9 0V9zm-2 2v9h13v-9h-13zM9 14.5h6v2H9v-2z\\"></path></svg></span></div></div></div></div></div></div>"`;

exports[`ssr snapshot test > ssr test src/date-picker/_example/date-presets-alt.jsx 1`] = `"<div style=\\"gap:16px\\" class=\\"t-space t-space-vertical\\"><div class=\\"t-space-item\\"><div class=\\"t-date-range-picker\\"><div class=\\"t-range-input-popup t-range-input-popup\\"><div class=\\"t-range-input t-is-default t-range-input--suffix\\" value=\\"2022-01-01,2022-08-08\\"><div class=\\"t-range-input__inner\\"><div class=\\"t-input__wrap t-range-input__inner-left\\" value=\\"2022-01-01\\"><div class=\\"t-input t-is-readonly t-align-left\\"><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"2022-01-01\\"/></div></div><div class=\\"t-range-input__inner-separator\\"> ~ </div><div class=\\"t-input__wrap t-range-input__inner-right\\" value=\\"2022-08-08\\"><div class=\\"t-input t-is-readonly t-align-left\\"><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"2022-08-08\\"/></div></div><span class=\\"t-range-input__suffix t-range-input__suffix-icon\\"><svg fill=\\"none\\" viewBox=\\"0 0 24 24\\" width=\\"1em\\" height=\\"1em\\" class=\\"t-icon t-icon-calendar\\"><path fill=\\"currentColor\\" d=\\"M6 4V1.5h2V4h8V1.5h2V4h4v18H2V4h4zM4 6v3h16V6H4zm16 5H4v9h16v-9z\\"></path></svg></span></div></div></div></div></div><div class=\\"t-space-item\\"><div class=\\"t-date-range-picker\\"><div class=\\"t-range-input-popup t-range-input-popup\\"><div class=\\"t-range-input t-is-default t-range-input--suffix\\" value=\\"2022-01-01 11:11:11,2022-08-08 12:12:12\\"><div class=\\"t-range-input__inner\\"><div class=\\"t-input__wrap t-range-input__inner-left\\" value=\\"2022-01-01 11:11:11\\"><div class=\\"t-input t-is-readonly t-align-left\\"><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"2022-01-01 11:11:11\\"/></div></div><div class=\\"t-range-input__inner-separator\\"> ~ </div><div class=\\"t-input__wrap t-range-input__inner-right\\" value=\\"2022-08-08 12:12:12\\"><div class=\\"t-input t-is-readonly t-align-left\\"><input placeholder=\\"select date\\" type=\\"text\\" class=\\"t-input__inner\\" readonly=\\"\\" value=\\"2022-08-08 12:12:12\\"/></div></div><span class=\\"t-range-input__suffix t-range-input__suffix-icon\\"><svg fill=\\"none\\" viewBox=\\"0 0 24 24\\" width=\\"1em\\" height=\\"1em\\" class=\\"t-icon t-icon-calendar\\"><path fill=\\"currentColor\\" d=\\"M6 4V1.5h2V4h8V1.5h2V4h4v18H2V4h4zM4 6v3h16V6H4zm16 5H4v9h16v-9z\\"></path></svg></span></div></div></div></div></div></div>"`;
Expand Down

0 comments on commit 91ebade

Please sign in to comment.