Skip to content

Commit

Permalink
identation fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
jomcarvajal committed Feb 4, 2025
1 parent 8ff25b2 commit d26b555
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 44 deletions.
66 changes: 33 additions & 33 deletions src/components/SectionNav.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,40 +3,40 @@ import renderer from 'react-test-renderer';

describe('SectionNav', () => {

const childrenListWithKeys = [
<button key='1'>Slide 1</button>,
<button key='2'>Slide 2</button>,
<button key='3'>Slide 3</button>,
<button key='4'>Slide 4</button>,
<button key='5'>Slide 5</button>,
];
const childrenListWithKeys = [
<button key='1'>Slide 1</button>,
<button key='2'>Slide 2</button>,
<button key='3'>Slide 3</button>,
<button key='4'>Slide 4</button>,
<button key='5'>Slide 5</button>,
];

const handlePrev = jest.fn();
const handleNext = jest.fn();
const handlePrev = jest.fn();
const handleNext = jest.fn();

it('matches snapshot', () => {
const tree = renderer.create(
<SectionNav
handlePrevArrow={handlePrev}
handleNextArrow={handleNext}
>
{childrenListWithKeys}
</SectionNav>
).toJSON();
expect(tree).toMatchSnapshot();
});
it('matches snapshot', () => {
const tree = renderer.create(
<SectionNav
handlePrevArrow={handlePrev}
handleNextArrow={handleNext}
>
{childrenListWithKeys}
</SectionNav>
).toJSON();
expect(tree).toMatchSnapshot();
});

it('matches snapshot when arrows are disabled', () => {
const tree = renderer.create(
<SectionNav
handlePrevArrow={handlePrev}
handleNextArrow={handleNext}
isPrevArrowDisabled
isNextArrowDisabled
>
{childrenListWithKeys}
</SectionNav>
).toJSON();
expect(tree).toMatchSnapshot();
});
it('matches snapshot when arrows are disabled', () => {
const tree = renderer.create(
<SectionNav
handlePrevArrow={handlePrev}
handleNextArrow={handleNext}
isPrevArrowDisabled
isNextArrowDisabled
>
{childrenListWithKeys}
</SectionNav>
).toJSON();
expect(tree).toMatchSnapshot();
});
});
2 changes: 1 addition & 1 deletion src/components/SectionNav/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export const SectionNavWrapper = styled.div`
export const SectionNavGroup = styled.div`
flex: 0 0 auto;
&:not(:last-child) {
margin-right: 1rem;
margin-right: 0.8rem;
}
`;

Expand Down
20 changes: 10 additions & 10 deletions src/components/__snapshots__/SectionNav.spec.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -27,35 +27,35 @@ exports[`SectionNav matches snapshot 1`] = `
className="sc-gsnTZi hTCAIx"
>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 1
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 2
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 3
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 4
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 5
Expand Down Expand Up @@ -111,35 +111,35 @@ exports[`SectionNav matches snapshot when arrows are disabled 1`] = `
className="sc-gsnTZi hTCAIx"
>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 1
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 2
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 3
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 4
</button>
</div>
<div
className="sc-dkzDqf hSvdjQ"
className="sc-dkzDqf Deoej"
>
<button>
Slide 5
Expand Down

0 comments on commit d26b555

Please sign in to comment.