Skip to content

Commit e4d876b

Browse files
committed
chore: eslint + prettier on all files
1 parent 8b2139e commit e4d876b

File tree

163 files changed

+1895
-1899
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

163 files changed

+1895
-1899
lines changed

packages/uui-action-bar/lib/uui-action-bar.story.ts

Lines changed: 25 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,13 @@ export const AAAOverview: StoryFn = props => html`
4343
<uui-icon-registry-essential>
4444
<uui-action-bar
4545
>${buttons.map(
46-
el => html` <uui-button
47-
label="${el}"
48-
look="${props.look}"
49-
color="${props.color}">
50-
<uui-icon name="${el}"></uui-icon>
51-
</uui-button>`
46+
el =>
47+
html` <uui-button
48+
label="${el}"
49+
look="${props.look}"
50+
color="${props.color}">
51+
<uui-icon name="${el}"></uui-icon>
52+
</uui-button>`,
5253
)}
5354
</uui-action-bar>
5455
</uui-icon-registry-essential>
@@ -62,14 +63,15 @@ export const Single = () => {
6263
return html`
6364
<uui-icon-registry-essential>
6465
${looks.map(
65-
look => html`<div
66-
style="display: grid; grid-template-columns: repeat( auto-fill, 120px ); gap: 16px; margin-bottom: 32px">
67-
<uui-action-bar style="justify-self: left;">
68-
<uui-button label="Delete" .look="${look as any}">
69-
<uui-icon name="delete"></uui-icon>
70-
</uui-button>
71-
</uui-action-bar>
72-
</div> `
66+
look =>
67+
html`<div
68+
style="display: grid; grid-template-columns: repeat( auto-fill, 120px ); gap: 16px; margin-bottom: 32px">
69+
<uui-action-bar style="justify-self: left;">
70+
<uui-button label="Delete" .look="${look as any}">
71+
<uui-icon name="delete"></uui-icon>
72+
</uui-button>
73+
</uui-action-bar>
74+
</div> `,
7375
)}
7476
</uui-icon-registry-essential>
7577
`;
@@ -89,17 +91,18 @@ export const LooksAndColors = () => {
8991
look => html`
9092
<uui-action-bar
9193
>${buttons.map(
92-
el => html` <uui-button
93-
label="${el}"
94-
.look="${look as any}"
95-
.color="${color as any}">
96-
<uui-icon name="${el}"></uui-icon>
97-
</uui-button>`
94+
el =>
95+
html` <uui-button
96+
label="${el}"
97+
.look="${look as any}"
98+
.color="${color as any}">
99+
<uui-icon name="${el}"></uui-icon>
100+
</uui-button>`,
98101
)}
99102
</uui-action-bar>
100-
`
103+
`,
101104
)}
102-
</div> `
105+
</div> `,
103106
)}
104107
</uui-icon-registry-essential>
105108
`;

packages/uui-avatar-group/lib/uui-avatar-group.test.ts

Lines changed: 21 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,13 @@ describe('UuiAvatarGroup', () => {
1414
});
1515

1616
it('renders correct numbers of avatars', async () => {
17-
const avatarGroup = await fixture(
18-
html`
19-
<uui-avatar-group
20-
><uui-avatar name="First Last"></uui-avatar
21-
><uui-avatar name="First Last"></uui-avatar
22-
><uui-avatar name="First Last"></uui-avatar
23-
></uui-avatar-group>
24-
`
25-
);
17+
const avatarGroup = await fixture(html`
18+
<uui-avatar-group
19+
><uui-avatar name="First Last"></uui-avatar
20+
><uui-avatar name="First Last"></uui-avatar
21+
><uui-avatar name="First Last"></uui-avatar
22+
></uui-avatar-group>
23+
`);
2624

2725
const slot = avatarGroup.shadowRoot!.querySelector('slot');
2826
const avatars = slot!.assignedNodes({ flatten: false });
@@ -51,12 +49,14 @@ describe('UuiAvatarGroup', () => {
5149
describe('UuiAvatarGroup Limit', async () => {
5250
let avatarGroup: UUIAvatarGroupElement;
5351
beforeEach(async () => {
54-
avatarGroup = await fixture(html` <uui-avatar-group .limit="${2}">
55-
<uui-avatar name="First Last"></uui-avatar>
56-
<uui-avatar name="First Last"></uui-avatar>
57-
<uui-avatar name="First Last"></uui-avatar>
58-
<uui-avatar name="First Last"></uui-avatar>
59-
</uui-avatar-group>`);
52+
avatarGroup = await fixture(
53+
html` <uui-avatar-group .limit="${2}">
54+
<uui-avatar name="First Last"></uui-avatar>
55+
<uui-avatar name="First Last"></uui-avatar>
56+
<uui-avatar name="First Last"></uui-avatar>
57+
<uui-avatar name="First Last"></uui-avatar>
58+
</uui-avatar-group>`,
59+
);
6060
});
6161

6262
it('Hides avatars correctly', () => {
@@ -72,10 +72,12 @@ describe('UuiAvatarGroup Limit', async () => {
7272
});
7373

7474
it('Does not show limit text when not set', async () => {
75-
avatarGroup = await fixture(html` <uui-avatar-group>
76-
<uui-avatar name="First Last"></uui-avatar>
77-
<uui-avatar name="First Last"></uui-avatar>
78-
</uui-avatar-group>`);
75+
avatarGroup = await fixture(
76+
html` <uui-avatar-group>
77+
<uui-avatar name="First Last"></uui-avatar>
78+
<uui-avatar name="First Last"></uui-avatar>
79+
</uui-avatar-group>`,
80+
);
7981

8082
const small = avatarGroup.shadowRoot!.querySelector('small');
8183
expect(small).to.not.exist;

packages/uui-avatar/lib/uui-avatar.story.ts

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,15 @@ const avatarSrcSet = [
3737
`${avatarSrc}&h=300&w=300`,
3838
];
3939

40-
const Template: Story = (props: any) => html`<uui-avatar
41-
.overflow=${props.overflow}
42-
.imgSrc=${props.imgSrc}
43-
.imgSrcset=${props.imgSrcset}
44-
.name=${props.name}
45-
style="font-size: ${props.fontSize}px; background-color: ${props.backgroundColor}; color: ${props.color}"
46-
>${props.slot}</uui-avatar
47-
>`;
40+
const Template: Story = (props: any) =>
41+
html`<uui-avatar
42+
.overflow=${props.overflow}
43+
.imgSrc=${props.imgSrc}
44+
.imgSrcset=${props.imgSrcset}
45+
.name=${props.name}
46+
style="font-size: ${props.fontSize}px; background-color: ${props.backgroundColor}; color: ${props.color}"
47+
>${props.slot}</uui-avatar
48+
>`;
4849

4950
export const AAAOverview = Template.bind({});
5051
AAAOverview.storyName = 'Overview';

packages/uui-avatar/lib/uui-avatar.test.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,19 +43,19 @@ describe('UuiAvatar', () => {
4343

4444
it('renders an image when imgSrc is set', async () => {
4545
const avatar = await fixture(
46-
html`<uui-avatar img-src="${avatarSrc}" name="My Avatar"></uui-avatar>`
46+
html`<uui-avatar img-src="${avatarSrc}" name="My Avatar"></uui-avatar>`,
4747
);
4848
expect(avatar).shadowDom.to.equal(
49-
`<img alt="MA" src="${avatarSrc}" srcset="" title="My Avatar" /><slot></<slot>`
49+
`<img alt="MA" src="${avatarSrc}" srcset="" title="My Avatar" /><slot></<slot>`,
5050
);
5151
});
5252

5353
it('renders an image with alt text when imgSrc and text is set', async () => {
5454
const avatar = await fixture(
55-
html`<uui-avatar img-src="${avatarSrc}" name="alt text"></uui-avatar>`
55+
html`<uui-avatar img-src="${avatarSrc}" name="alt text"></uui-avatar>`,
5656
);
5757
expect(avatar).shadowDom.to.equal(
58-
`<img alt="AT" src="${avatarSrc}" srcset="" title="alt text" /><slot></<slot>`
58+
`<img alt="AT" src="${avatarSrc}" srcset="" title="alt text" /><slot></<slot>`,
5959
);
6060
});
6161

@@ -66,7 +66,7 @@ describe('UuiAvatar', () => {
6666

6767
it('shows the first and last initial when text is used and there is no image', async () => {
6868
const avatar = await fixture(
69-
html`<uui-avatar name="First Second Last"></uui-avatar>`
69+
html`<uui-avatar name="First Second Last"></uui-avatar>`,
7070
);
7171
expect(avatar).shadowDom.to.equal('FL<slot></<slot>');
7272
});

packages/uui-badge/lib/uui-badge.story.ts

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -38,17 +38,18 @@ export default {
3838
},
3939
};
4040

41-
const Template: Story = props => html` <uui-icon-registry-essential>
42-
<div
43-
style="position:relative; width:80px; height:80px; border: 1px dashed rgba(0,0,0,0.1)">
44-
<uui-badge
45-
.color=${props.color}
46-
.look=${props.look}
47-
?attention=${props.attention}
48-
>${props.slot}</uui-badge
49-
>
50-
</div>
51-
</uui-icon-registry-essential>`;
41+
const Template: Story = props =>
42+
html` <uui-icon-registry-essential>
43+
<div
44+
style="position:relative; width:80px; height:80px; border: 1px dashed rgba(0,0,0,0.1)">
45+
<uui-badge
46+
.color=${props.color}
47+
.look=${props.look}
48+
?attention=${props.attention}
49+
>${props.slot}</uui-badge
50+
>
51+
</div>
52+
</uui-icon-registry-essential>`;
5253

5354
export const AAAOverview = Template.bind({});
5455
AAAOverview.args = {
@@ -128,10 +129,11 @@ WithIcon.parameters = {
128129
},
129130
};
130131

131-
export const OnButton: Story = props => html` <uui-button look="outline">
132-
Button label
133-
<uui-badge .color=${props.color}>${props.slot}</uui-badge>
134-
</uui-button>`;
132+
export const OnButton: Story = props =>
133+
html` <uui-button look="outline">
134+
Button label
135+
<uui-badge .color=${props.color}>${props.slot}</uui-badge>
136+
</uui-button>`;
135137
OnButton.args = {
136138
color: 'danger',
137139
slot: '!',
@@ -156,27 +158,25 @@ function uppercaseFirstLetter(s: string) {
156158
return s.charAt(0).toUpperCase() + s.slice(1);
157159
}
158160

159-
export const LooksAndColors: Story = () =>
160-
html`
161-
${colors.map(
162-
color =>
163-
html`
164-
<h5>${uppercaseFirstLetter(color)}</h5>
165-
<div style="margin-bottom: 32px; display: flex; gap: 16px;">
166-
${looks.map(
167-
look => html`
168-
<div
169-
style="position:relative; width:100px; height:80px; border: 1px dashed rgba(0,0,0,0.1); margin-top: 16px">
170-
<uui-badge
171-
.look=${look as any}
172-
.color=${color as any}
173-
style="margin-right:12px;"
174-
>${uppercaseFirstLetter(look)}</uui-badge
175-
>
176-
</div>
177-
`
178-
)}
179-
</div>
180-
`
181-
)}
182-
`;
161+
export const LooksAndColors: Story = () => html`
162+
${colors.map(
163+
color => html`
164+
<h5>${uppercaseFirstLetter(color)}</h5>
165+
<div style="margin-bottom: 32px; display: flex; gap: 16px;">
166+
${looks.map(
167+
look => html`
168+
<div
169+
style="position:relative; width:100px; height:80px; border: 1px dashed rgba(0,0,0,0.1); margin-top: 16px">
170+
<uui-badge
171+
.look=${look as any}
172+
.color=${color as any}
173+
style="margin-right:12px;"
174+
>${uppercaseFirstLetter(look)}</uui-badge
175+
>
176+
</div>
177+
`,
178+
)}
179+
</div>
180+
`,
181+
)}
182+
`;

packages/uui-base/lib/animations/uui-pulse.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,5 @@ export const UUIHorizontalPulseKeyframes = css`
2323
`;
2424

2525
export const UUIHorizontalPulseAnimationValue = unsafeCSS(
26-
'pulse 0.8s ease-in-out infinite both'
26+
'pulse 0.8s ease-in-out infinite both',
2727
);

packages/uui-base/lib/animations/uui-shake.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,5 @@ export const UUIHorizontalShakeKeyframes = css`
2828
`;
2929

3030
export const UUIHorizontalShakeAnimationValue = unsafeCSS(
31-
'uui-horizontal-shake 600ms ease backwards'
31+
'uui-horizontal-shake 600ms ease backwards',
3232
);

packages/uui-base/lib/events/UUIEvent.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
export class UUIEvent<
66
DetailType extends Record<string, any> = Record<string, any>,
7-
EventTargetType extends EventTarget | null = EventTarget | null
7+
EventTargetType extends EventTarget | null = EventTarget | null,
88
> extends Event {
99
readonly detail: DetailType;
1010
readonly target!: EventTargetType;

packages/uui-base/lib/mixins/ActiveMixin.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export declare class ActiveMixinInterface {
1414
* @mixin
1515
*/
1616
export const ActiveMixin = <T extends Constructor<LitElement>>(
17-
superClass: T
17+
superClass: T,
1818
) => {
1919
class ActiveMixinClass extends superClass {
2020
/**

packages/uui-base/lib/mixins/FormControlMixin.story.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ export default {
88
title: 'Inputs/Form/FormControlMixin',
99
};
1010

11-
export const AAAOverview: Story = () =>
12-
html`
13-
<p>FormControlMixin can be used to make a web component part of a form.</p>
14-
`;
11+
export const AAAOverview: Story = () => html`
12+
<p>FormControlMixin can be used to make a web component part of a form.</p>
13+
`;
1514
AAAOverview.storyName = 'Overview';

0 commit comments

Comments
 (0)