Files
shlink-web-client/test/servers/__snapshots__/ManageServersRow.test.tsx.snap
2025-11-14 19:23:48 +01:00

167 lines
6.7 KiB
Plaintext

// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
exports[`<ManageServersRow /> > renders auto-connect icon only if server is autoConnect 1`] = `
<div>
<table
class="w-full"
>
<thead
class="hidden lg:table-header-group"
>
<tr
class="group lg:table-row flex flex-col lg:border-0 border-y-2 border-lm-border dark:border-dm-border"
/>
</thead>
<tbody
class="lg:table-row-group flex flex-col gap-y-3"
>
<tr
class="group lg:table-row flex flex-col lg:border-0 border-y-2 border-lm-border dark:border-dm-border hover:bg-lm-primary dark:hover:bg-dm-primary group-[&]/card:hover:bg-lm-secondary dark:group-[&]/card:hover:bg-dm-secondary relative"
>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1"
data-column="Auto-connect"
>
<svg
aria-hidden="true"
class="svg-inline--fa fa-check text-lm-brand dark:text-dm-brand"
data-icon="check"
data-prefix="fas"
data-testid="auto-connect"
role="img"
viewBox="0 0 448 512"
>
<path
d="M434.8 70.1c14.3 10.4 17.5 30.4 7.1 44.7l-256 352c-5.5 7.6-14 12.3-23.4 13.1s-18.5-2.7-25.1-9.3l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l101.5 101.5 234-321.7c10.4-14.3 30.4-17.5 44.7-7.1z"
fill="currentColor"
/>
</svg>
</td>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1 font-bold"
data-column="Name"
>
<a
data-discover="true"
href="/server/abc"
>
My server
</a>
</td>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1 max-lg:border-b-0"
data-column="Base URL"
>
https://example.com
</td>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1 text-right max-lg:absolute right-0 -top-1 mx-lg:pt-0"
>
<div
class="relative inline-block"
>
<button
aria-controls="_r_o_"
aria-expanded="false"
aria-haspopup="true"
aria-label="Options"
class="flex items-center rounded-md focus-ring cursor-pointer border border-lm-border dark:border-dm-border bg-lm-primary dark:bg-dm-primary group-[&]/card:bg-lm-input group-[&]/card:dark:bg-dm-input px-3 py-1.5 gap-x-2"
type="button"
>
<svg
aria-hidden="true"
class="svg-inline--fa fa-ellipsis-vertical fa-width-auto"
data-icon="ellipsis-vertical"
data-prefix="fas"
role="img"
viewBox="0 0 128 512"
>
<path
d="M64 144a56 56 0 1 1 0-112 56 56 0 1 1 0 112zm0 224c30.9 0 56 25.1 56 56s-25.1 56-56 56-56-25.1-56-56 25.1-56 56-56zm56-112c0 30.9-25.1 56-56 56s-56-25.1-56-56 25.1-56 56-56 56 25.1 56 56z"
fill="currentColor"
/>
</svg>
</button>
</div>
</td>
</tr>
</tbody>
</table>
</div>
`;
exports[`<ManageServersRow /> > renders auto-connect icon only if server is autoConnect 2`] = `
<div>
<table
class="w-full"
>
<thead
class="hidden lg:table-header-group"
>
<tr
class="group lg:table-row flex flex-col lg:border-0 border-y-2 border-lm-border dark:border-dm-border"
/>
</thead>
<tbody
class="lg:table-row-group flex flex-col gap-y-3"
>
<tr
class="group lg:table-row flex flex-col lg:border-0 border-y-2 border-lm-border dark:border-dm-border hover:bg-lm-primary dark:hover:bg-dm-primary group-[&]/card:hover:bg-lm-secondary dark:group-[&]/card:hover:bg-dm-secondary relative"
>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1"
data-column="Auto-connect"
/>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1 font-bold"
data-column="Name"
>
<a
data-discover="true"
href="/server/abc"
>
My server
</a>
</td>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1 max-lg:border-b-0"
data-column="Base URL"
>
https://example.com
</td>
<td
class="border-lm-border dark:border-dm-border p-2 block lg:table-cell not-last:border-b-1 lg:border-b-1 before:lg:hidden before:content-[attr(data-column)] before:font-bold before:mr-1 text-right max-lg:absolute right-0 -top-1 mx-lg:pt-0"
>
<div
class="relative inline-block"
>
<button
aria-controls="_r_t_"
aria-expanded="false"
aria-haspopup="true"
aria-label="Options"
class="flex items-center rounded-md focus-ring cursor-pointer border border-lm-border dark:border-dm-border bg-lm-primary dark:bg-dm-primary group-[&]/card:bg-lm-input group-[&]/card:dark:bg-dm-input px-3 py-1.5 gap-x-2"
type="button"
>
<svg
aria-hidden="true"
class="svg-inline--fa fa-ellipsis-vertical fa-width-auto"
data-icon="ellipsis-vertical"
data-prefix="fas"
role="img"
viewBox="0 0 128 512"
>
<path
d="M64 144a56 56 0 1 1 0-112 56 56 0 1 1 0 112zm0 224c30.9 0 56 25.1 56 56s-25.1 56-56 56-56-25.1-56-56 25.1-56 56-56zm56-112c0 30.9-25.1 56-56 56s-56-25.1-56-56 25.1-56 56-56 56 25.1 56 56z"
fill="currentColor"
/>
</svg>
</button>
</div>
</td>
</tr>
</tbody>
</table>
</div>
`;