Skip to content

Commit

Permalink
Refactor snapshot folders:
Browse files Browse the repository at this point in the history
Button.spec.js.snap
Chip.spec.js.snap
Fieldset.spec.js.snap
Message.spec.js.snap
  • Loading branch information
habubey committed Apr 19, 2023
1 parent 6316006 commit abe4aa3
Show file tree
Hide file tree
Showing 4 changed files with 352 additions and 43 deletions.
34 changes: 30 additions & 4 deletions components/lib/button/__snapshots__/Button.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,38 @@ exports[`Button when click the button if loading is false it renders Button with
exports[`Button when click the button if loading is true it renders Button with loading icon 1`] = `
<div>
<button
class="p-button p-component p-button-icon-only p-disabled p-button-loading"
class="p-button p-component p-disabled p-button-loading"
disabled=""
>
<span
class="p-button-icon p-c p-button-loading-icon pi pi-spinner pi-spin"
/>
<svg
aria-hidden="true"
class="p-icon p-icon-spin p-button-icon p-c p-button-loading-icon"
fill="none"
height="14"
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<g
clip-path="url(#clip0_417_21408)"
>
<path
d="M6.99701 14C5.85441 13.999 4.72939 13.7186 3.72012 13.1832C2.71084 12.6478 1.84795 11.8737 1.20673 10.9284C0.565504 9.98305 0.165424 8.89526 0.041387 7.75989C-0.0826496 6.62453 0.073125 5.47607 0.495122 4.4147C0.917119 3.35333 1.59252 2.4113 2.46241 1.67077C3.33229 0.930247 4.37024 0.413729 5.4857 0.166275C6.60117 -0.0811796 7.76026 -0.0520535 8.86188 0.251112C9.9635 0.554278 10.9742 1.12227 11.8057 1.90555C11.915 2.01493 11.9764 2.16319 11.9764 2.31778C11.9764 2.47236 11.915 2.62062 11.8057 2.73C11.7521 2.78503 11.688 2.82877 11.6171 2.85864C11.5463 2.8885 11.4702 2.90389 11.3933 2.90389C11.3165 2.90389 11.2404 2.8885 11.1695 2.85864C11.0987 2.82877 11.0346 2.78503 10.9809 2.73C9.9998 1.81273 8.73246 1.26138 7.39226 1.16876C6.05206 1.07615 4.72086 1.44794 3.62279 2.22152C2.52471 2.99511 1.72683 4.12325 1.36345 5.41602C1.00008 6.70879 1.09342 8.08723 1.62775 9.31926C2.16209 10.5513 3.10478 11.5617 4.29713 12.1803C5.48947 12.7989 6.85865 12.988 8.17414 12.7157C9.48963 12.4435 10.6711 11.7264 11.5196 10.6854C12.3681 9.64432 12.8319 8.34282 12.8328 7C12.8328 6.84529 12.8943 6.69692 13.0038 6.58752C13.1132 6.47812 13.2616 6.41667 13.4164 6.41667C13.5712 6.41667 13.7196 6.47812 13.8291 6.58752C13.9385 6.69692 14 6.84529 14 7C14 8.85651 13.2622 10.637 11.9489 11.9497C10.6356 13.2625 8.85432 14 6.99701 14Z"
fill="currentColor"
/>
</g>
<defs>
<clippath
id="clip0_417_21408"
>
<rect
fill="white"
height="14"
width="14"
/>
</clippath>
</defs>
</svg>
<span
class="p-button-label p-c"
>
Expand Down
68 changes: 62 additions & 6 deletions components/lib/chip/__snapshots__/Chip.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,38 @@ exports[`Chip when removable is true it returns with remove icon: before remove
<div
class="p-chip p-component"
>
<span
class="p-chip-remove-icon pi pi-times-circle"
<svg
aria-hidden="true"
class="p-icon p-chip-remove-icon"
fill="none"
height="14"
tabindex="0"
/>
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<g
clip-path="url(#clip0_334_13179)"
>
<path
clip-rule="evenodd"
d="M7 14C5.61553 14 4.26215 13.5895 3.11101 12.8203C1.95987 12.0511 1.06266 10.9579 0.532846 9.67879C0.00303296 8.3997 -0.13559 6.99224 0.134506 5.63437C0.404603 4.2765 1.07129 3.02922 2.05026 2.05026C3.02922 1.07129 4.2765 0.404603 5.63437 0.134506C6.99224 -0.13559 8.3997 0.00303296 9.67879 0.532846C10.9579 1.06266 12.0511 1.95987 12.8203 3.11101C13.5895 4.26215 14 5.61553 14 7C14 8.85652 13.2625 10.637 11.9497 11.9497C10.637 13.2625 8.85652 14 7 14ZM7 1.16667C5.84628 1.16667 4.71846 1.50879 3.75918 2.14976C2.79989 2.79074 2.05222 3.70178 1.61071 4.76768C1.16919 5.83358 1.05367 7.00647 1.27876 8.13803C1.50384 9.26958 2.05941 10.309 2.87521 11.1248C3.69102 11.9406 4.73042 12.4962 5.86198 12.7212C6.99353 12.9463 8.16642 12.8308 9.23232 12.3893C10.2982 11.9478 11.2093 11.2001 11.8502 10.2408C12.4912 9.28154 12.8333 8.15373 12.8333 7C12.8333 5.45291 12.2188 3.96918 11.1248 2.87521C10.0308 1.78125 8.5471 1.16667 7 1.16667ZM4.66662 9.91668C4.58998 9.91704 4.51404 9.90209 4.44325 9.87271C4.37246 9.84333 4.30826 9.8001 4.2544 9.74557C4.14516 9.6362 4.0838 9.48793 4.0838 9.33335C4.0838 9.17876 4.14516 9.0305 4.2544 8.92113L6.17553 7L4.25443 5.07891C4.15139 4.96832 4.09529 4.82207 4.09796 4.67094C4.10063 4.51982 4.16185 4.37563 4.26872 4.26876C4.3756 4.16188 4.51979 4.10066 4.67091 4.09799C4.82204 4.09532 4.96829 4.15142 5.07887 4.25446L6.99997 6.17556L8.92106 4.25446C9.03164 4.15142 9.1779 4.09532 9.32903 4.09799C9.48015 4.10066 9.62434 4.16188 9.73121 4.26876C9.83809 4.37563 9.89931 4.51982 9.90198 4.67094C9.90464 4.82207 9.84855 4.96832 9.74551 5.07891L7.82441 7L9.74554 8.92113C9.85478 9.0305 9.91614 9.17876 9.91614 9.33335C9.91614 9.48793 9.85478 9.6362 9.74554 9.74557C9.69168 9.8001 9.62748 9.84333 9.55669 9.87271C9.4859 9.90209 9.40996 9.91704 9.33332 9.91668C9.25668 9.91704 9.18073 9.90209 9.10995 9.87271C9.03916 9.84333 8.97495 9.8001 8.9211 9.74557L6.99997 7.82444L5.07884 9.74557C5.02499 9.8001 4.96078 9.84333 4.88999 9.87271C4.81921 9.90209 4.74326 9.91704 4.66662 9.91668Z"
fill="currentColor"
fill-rule="evenodd"
/>
</g>
<defs>
<clippath
id="clip0_334_13179"
>
<rect
fill="white"
height="14"
width="14"
/>
</clippath>
</defs>
</svg>
</div>
</div>
`;
Expand All @@ -82,10 +110,38 @@ exports[`Chip when removable is true the chip is removed when ENTER is pressed:
<div
class="p-chip p-component"
>
<span
class="p-chip-remove-icon pi pi-times-circle"
<svg
aria-hidden="true"
class="p-icon p-chip-remove-icon"
fill="none"
height="14"
tabindex="0"
/>
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<g
clip-path="url(#clip0_334_13179)"
>
<path
clip-rule="evenodd"
d="M7 14C5.61553 14 4.26215 13.5895 3.11101 12.8203C1.95987 12.0511 1.06266 10.9579 0.532846 9.67879C0.00303296 8.3997 -0.13559 6.99224 0.134506 5.63437C0.404603 4.2765 1.07129 3.02922 2.05026 2.05026C3.02922 1.07129 4.2765 0.404603 5.63437 0.134506C6.99224 -0.13559 8.3997 0.00303296 9.67879 0.532846C10.9579 1.06266 12.0511 1.95987 12.8203 3.11101C13.5895 4.26215 14 5.61553 14 7C14 8.85652 13.2625 10.637 11.9497 11.9497C10.637 13.2625 8.85652 14 7 14ZM7 1.16667C5.84628 1.16667 4.71846 1.50879 3.75918 2.14976C2.79989 2.79074 2.05222 3.70178 1.61071 4.76768C1.16919 5.83358 1.05367 7.00647 1.27876 8.13803C1.50384 9.26958 2.05941 10.309 2.87521 11.1248C3.69102 11.9406 4.73042 12.4962 5.86198 12.7212C6.99353 12.9463 8.16642 12.8308 9.23232 12.3893C10.2982 11.9478 11.2093 11.2001 11.8502 10.2408C12.4912 9.28154 12.8333 8.15373 12.8333 7C12.8333 5.45291 12.2188 3.96918 11.1248 2.87521C10.0308 1.78125 8.5471 1.16667 7 1.16667ZM4.66662 9.91668C4.58998 9.91704 4.51404 9.90209 4.44325 9.87271C4.37246 9.84333 4.30826 9.8001 4.2544 9.74557C4.14516 9.6362 4.0838 9.48793 4.0838 9.33335C4.0838 9.17876 4.14516 9.0305 4.2544 8.92113L6.17553 7L4.25443 5.07891C4.15139 4.96832 4.09529 4.82207 4.09796 4.67094C4.10063 4.51982 4.16185 4.37563 4.26872 4.26876C4.3756 4.16188 4.51979 4.10066 4.67091 4.09799C4.82204 4.09532 4.96829 4.15142 5.07887 4.25446L6.99997 6.17556L8.92106 4.25446C9.03164 4.15142 9.1779 4.09532 9.32903 4.09799C9.48015 4.10066 9.62434 4.16188 9.73121 4.26876C9.83809 4.37563 9.89931 4.51982 9.90198 4.67094C9.90464 4.82207 9.84855 4.96832 9.74551 5.07891L7.82441 7L9.74554 8.92113C9.85478 9.0305 9.91614 9.17876 9.91614 9.33335C9.91614 9.48793 9.85478 9.6362 9.74554 9.74557C9.69168 9.8001 9.62748 9.84333 9.55669 9.87271C9.4859 9.90209 9.40996 9.91704 9.33332 9.91668C9.25668 9.91704 9.18073 9.90209 9.10995 9.87271C9.03916 9.84333 8.97495 9.8001 8.9211 9.74557L6.99997 7.82444L5.07884 9.74557C5.02499 9.8001 4.96078 9.84333 4.88999 9.87271C4.81921 9.90209 4.74326 9.91704 4.66662 9.91668Z"
fill="currentColor"
fill-rule="evenodd"
/>
</g>
<defs>
<clippath
id="clip0_334_13179"
>
<rect
fill="white"
height="14"
width="14"
/>
</clippath>
</defs>
</svg>
</div>
</div>
`;
100 changes: 85 additions & 15 deletions components/lib/fieldset/__snapshots__/Fieldset.spec.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,35 @@ exports[`Fieldset when Fieldset is toggleable it must expand and collapse: expan
href="#pr_id_3_content"
id="pr_id_3_header"
>
<span
class="p-fieldset-toggler pi pi-plus"
/>
<svg
aria-hidden="true"
class="p-icon p-fieldset-toggler"
fill="none"
height="14"
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<g
clip-path="url(#clip0_306_11939)"
>
<path
d="M7.67742 6.32258V0.677419C7.67742 0.497757 7.60605 0.325452 7.47901 0.198411C7.35197 0.0713707 7.17966 0 7 0C6.82034 0 6.64803 0.0713707 6.52099 0.198411C6.39395 0.325452 6.32258 0.497757 6.32258 0.677419V6.32258H0.677419C0.497757 6.32258 0.325452 6.39395 0.198411 6.52099C0.0713707 6.64803 0 6.82034 0 7C0 7.17966 0.0713707 7.35197 0.198411 7.47901C0.325452 7.60605 0.497757 7.67742 0.677419 7.67742H6.32258V13.3226C6.32492 13.5015 6.39704 13.6725 6.52358 13.799C6.65012 13.9255 6.82106 13.9977 7 14C7.17966 14 7.35197 13.9286 7.47901 13.8016C7.60605 13.6745 7.67742 13.5022 7.67742 13.3226V7.67742H13.3226C13.5022 7.67742 13.6745 7.60605 13.8016 7.47901C13.9286 7.35197 14 7.17966 14 7C13.9977 6.82106 13.9255 6.65012 13.799 6.52358C13.6725 6.39704 13.5015 6.32492 13.3226 6.32258H7.67742Z"
fill="currentColor"
/>
</g>
<defs>
<clippath
id="clip0_306_11939"
>
<rect
fill="white"
height="14"
width="14"
/>
</clippath>
</defs>
</svg>
<span
class="p-fieldset-legend-text"
>
Expand Down Expand Up @@ -113,9 +139,20 @@ exports[`Fieldset when Fieldset is toggleable it must expand and collapse: expan
href="#pr_id_3_content"
id="pr_id_3_header"
>
<span
class="p-fieldset-toggler pi pi-minus"
/>
<svg
aria-hidden="true"
class="p-icon p-fieldset-toggler"
fill="none"
height="14"
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M13.2222 7.77778H0.777778C0.571498 7.77778 0.373667 7.69584 0.227806 7.54998C0.0819442 7.40412 0 7.20629 0 7.00001C0 6.79373 0.0819442 6.5959 0.227806 6.45003C0.373667 6.30417 0.571498 6.22223 0.777778 6.22223H13.2222C13.4285 6.22223 13.6263 6.30417 13.7722 6.45003C13.9181 6.5959 14 6.79373 14 7.00001C14 7.20629 13.9181 7.40412 13.7722 7.54998C13.6263 7.69584 13.4285 7.77778 13.2222 7.77778Z"
fill="currentColor"
/>
</svg>
<span
class="p-fieldset-legend-text"
>
Expand Down Expand Up @@ -156,9 +193,20 @@ exports[`Fieldset when Fieldset is toggleable it must expand and collapse: expan
href="#pr_id_3_content"
id="pr_id_3_header"
>
<span
class="p-fieldset-toggler pi pi-minus"
/>
<svg
aria-hidden="true"
class="p-icon p-fieldset-toggler"
fill="none"
height="14"
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M13.2222 7.77778H0.777778C0.571498 7.77778 0.373667 7.69584 0.227806 7.54998C0.0819442 7.40412 0 7.20629 0 7.00001C0 6.79373 0.0819442 6.5959 0.227806 6.45003C0.373667 6.30417 0.571498 6.22223 0.777778 6.22223H13.2222C13.4285 6.22223 13.6263 6.30417 13.7722 6.45003C13.9181 6.5959 14 6.79373 14 7.00001C14 7.20629 13.9181 7.40412 13.7722 7.54998C13.6263 7.69584 13.4285 7.77778 13.2222 7.77778Z"
fill="currentColor"
/>
</svg>
<span
class="p-fieldset-legend-text"
>
Expand Down Expand Up @@ -200,9 +248,20 @@ exports[`Fieldset when Fieldset is toggleable it will toggle when clicked: toggl
href="#pr_id_2_content"
id="pr_id_2_header"
>
<span
class="p-fieldset-toggler pi pi-minus"
/>
<svg
aria-hidden="true"
class="p-icon p-fieldset-toggler"
fill="none"
height="14"
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M13.2222 7.77778H0.777778C0.571498 7.77778 0.373667 7.69584 0.227806 7.54998C0.0819442 7.40412 0 7.20629 0 7.00001C0 6.79373 0.0819442 6.5959 0.227806 6.45003C0.373667 6.30417 0.571498 6.22223 0.777778 6.22223H13.2222C13.4285 6.22223 13.6263 6.30417 13.7722 6.45003C13.9181 6.5959 14 6.79373 14 7.00001C14 7.20629 13.9181 7.40412 13.7722 7.54998C13.6263 7.69584 13.4285 7.77778 13.2222 7.77778Z"
fill="currentColor"
/>
</svg>
<span
class="p-fieldset-legend-text"
>
Expand Down Expand Up @@ -243,9 +302,20 @@ exports[`Fieldset when Fieldset is toggleable it will toggle when clicked: toggl
href="#pr_id_2_content"
id="pr_id_2_header"
>
<span
class="p-fieldset-toggler pi pi-minus"
/>
<svg
aria-hidden="true"
class="p-icon p-fieldset-toggler"
fill="none"
height="14"
viewBox="0 0 14 14"
width="14"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M13.2222 7.77778H0.777778C0.571498 7.77778 0.373667 7.69584 0.227806 7.54998C0.0819442 7.40412 0 7.20629 0 7.00001C0 6.79373 0.0819442 6.5959 0.227806 6.45003C0.373667 6.30417 0.571498 6.22223 0.777778 6.22223H13.2222C13.4285 6.22223 13.6263 6.30417 13.7722 6.45003C13.9181 6.5959 14 6.79373 14 7.00001C14 7.20629 13.9181 7.40412 13.7722 7.54998C13.6263 7.69584 13.4285 7.77778 13.2222 7.77778Z"
fill="currentColor"
/>
</svg>
<span
class="p-fieldset-legend-text"
>
Expand Down
Loading

0 comments on commit abe4aa3

Please sign in to comment.