Skip to content

Commit 77203fe

Browse files
Enable Prettier "quoteProps": "consistent"
1 parent c23824b commit 77203fe

File tree

4 files changed

+18
-17
lines changed

4 files changed

+18
-17
lines changed

.prettierrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"printWidth": 100,
3+
"quoteProps": "consistent",
34
"semi": true,
45
"singleQuote": true,
56
"tabWidth": 2,

src/components/form-elements/character-count/CharacterCount.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,12 @@ export const CharacterCount = forwardRef<HTMLTextAreaElement, CharacterCountProp
3434
inputType="textarea"
3535
formGroupProps={{
3636
...formGroupProps,
37-
className: classNames('nhsuk-character-count', formGroupProps?.className),
37+
'className': classNames('nhsuk-character-count', formGroupProps?.className),
3838
'data-module': 'nhsuk-character-count',
3939
'data-maxlength': maxLength,
4040
'data-maxwords': maxWords,
4141
'data-threshold': threshold,
42-
ref: moduleRef,
42+
'ref': moduleRef,
4343
}}
4444
{...rest}
4545
>

src/components/navigation/header/HeaderContext.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ import { createContext, type Dispatch, type SetStateAction } from 'react';
22

33
export interface IHeaderContext {
44
logoProps?: {
5-
href?: string;
6-
src?: string;
7-
alt?: string;
5+
'href'?: string;
6+
'src'?: string;
7+
'alt'?: string;
88
'aria-label'?: string;
99
};
1010
serviceProps?: {

src/util/types/FormTypes.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,22 +7,22 @@ import { type LabelProps } from '#components/form-elements/label/index.js';
77
import { type LegendProps } from '#components/form-elements/legend/index.js';
88

99
export interface FormElementProps {
10-
fieldsetProps?: FieldsetProps;
11-
legend?: string;
12-
legendProps?: LegendProps;
13-
label?: string;
14-
labelProps?: LabelProps;
15-
error?: string;
16-
errorProps?: ErrorMessageProps;
17-
hint?: string;
18-
hintProps?: HintTextProps;
19-
formGroupProps?: ComponentPropsWithRef<'div'> & {
10+
'fieldsetProps'?: FieldsetProps;
11+
'legend'?: string;
12+
'legendProps'?: LegendProps;
13+
'label'?: string;
14+
'labelProps'?: LabelProps;
15+
'error'?: string;
16+
'errorProps'?: ErrorMessageProps;
17+
'hint'?: string;
18+
'hintProps'?: HintTextProps;
19+
'formGroupProps'?: ComponentPropsWithRef<'div'> & {
2020
'data-module'?: string;
2121
'data-maxlength'?: number;
2222
'data-maxwords'?: number;
2323
'data-threshold'?: number;
2424
};
25-
id?: string;
26-
name?: string;
25+
'id'?: string;
26+
'name'?: string;
2727
'aria-describedby'?: string;
2828
}

0 commit comments

Comments
 (0)