Skip to content

Commit 657c9da

Browse files
renovate[bot]danez
andauthored
chore(deps): update dependency prettier to v3.9.5 (#1105)
* chore(deps): update dependency prettier to v3.9.5 * fix * fix --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Daniel Tschinder <code@tschinder.de>
1 parent bee950a commit 657c9da

6 files changed

Lines changed: 32 additions & 29 deletions

File tree

.github/scripts/create-changeset-from-pr.mjs

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ if (!prTitle) {
2020
}
2121

2222
if (!['add-changeset', 'add-changeset-major'].includes(labelName)) {
23-
console.log(`Skipping changeset creation because label ${labelName || 'unknown'} was not handled.`);
23+
console.log(
24+
`Skipping changeset creation because label ${labelName || 'unknown'} was not handled.`,
25+
);
2426
process.exit(0);
2527
}
2628

@@ -32,7 +34,11 @@ if (labelName === 'add-changeset-major') {
3234
releaseType = 'major';
3335
} else if (/^(feat|feature)(\([^)]+\))?!?:/i.test(message)) {
3436
releaseType = 'minor';
35-
} else if (/^(fix|perf|refactor|build|ci|chore|docs|style|test|revert)(\([^)]+\))?!?:/i.test(message)) {
37+
} else if (
38+
/^(fix|perf|refactor|build|ci|chore|docs|style|test|revert)(\([^)]+\))?!?:/i.test(
39+
message,
40+
)
41+
) {
3642
releaseType = 'patch';
3743
} else if (/\bbreaking change\b|!:/i.test(message)) {
3844
releaseType = 'major';
@@ -42,17 +48,22 @@ const fileName = `pr-${prNumber}.md`;
4248
const filePath = path.join(changesetDir, fileName);
4349

4450
const existingFiles = await readdir(changesetDir);
51+
4552
await Promise.all(
4653
existingFiles
4754
.filter((name) => name.startsWith(`pr-${prNumber}`) && name.endsWith('.md'))
48-
.map((name) => rm(path.join(changesetDir, name), { force: true }))
55+
.map((name) => rm(path.join(changesetDir, name), { force: true })),
4956
);
5057

51-
const packages = ["react-docgen", "react-docgen-cli"];
52-
const frontmatter = packages.map((pkg) => `"${pkg}": ${releaseType}`).join('\n');
58+
const packages = ['react-docgen', 'react-docgen-cli'];
59+
const frontmatter = packages
60+
.map((pkg) => `"${pkg}": ${releaseType}`)
61+
.join('\n');
5362
const content = `---\n${frontmatter}\n---\n\n${prTitle}\n`;
5463

5564
await mkdir(changesetDir, { recursive: true });
5665
await writeFile(filePath, content, 'utf8');
5766

58-
console.log(`Created changeset ${path.relative(repoRoot, filePath)} with release type ${releaseType}.`);
67+
console.log(
68+
`Created changeset ${path.relative(repoRoot, filePath)} with release type ${releaseType}.`,
69+
);

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
"execa": "9.6.1",
3232
"globals": "17.7.0",
3333
"nx": "23.1.0",
34-
"prettier": "3.8.4",
34+
"prettier": "3.9.5",
3535
"prettier-plugin-tailwindcss": "0.8.1",
3636
"rimraf": "6.1.3",
3737
"tempy": "3.2.0",

packages/react-docgen/src/Documentation.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -129,11 +129,7 @@ export interface ObjectSignatureType<
129129
}
130130

131131
export type TypeDescriptor<T = FunctionSignatureType> =
132-
| ElementsType<T>
133-
| LiteralType
134-
| ObjectSignatureType<T>
135-
| SimpleType
136-
| T;
132+
ElementsType<T> | LiteralType | ObjectSignatureType<T> | SimpleType | T;
137133

138134
export interface PropDescriptor {
139135
type?: PropTypeDescriptor;

packages/react-docgen/src/handlers/componentDocblockHandler.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,7 @@ function getDocblockFromComponent(path: NodePath): string | null {
1212

1313
if (path.isClassDeclaration() || path.isClassExpression()) {
1414
const decorators = path.get('decorators') as
15-
| Array<NodePath<Decorator>>
16-
| null
17-
| undefined;
15+
Array<NodePath<Decorator>> | null | undefined;
1816

1917
// If we have a class declaration or expression, then the comment might be
2018
// attached to the last decorator instead as trailing comment.

packages/react-docgen/src/utils/ts-types/index.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,7 @@ import type {
88
} from '@babel/types';
99

1010
type BindingNode =
11-
| TSEnumDeclaration
12-
| TSInterfaceDeclaration
13-
| TSTypeAliasDeclaration;
11+
TSEnumDeclaration | TSInterfaceDeclaration | TSTypeAliasDeclaration;
1412

1513
type TypeKind = 'alias' | 'enum' | 'interface';
1614

pnpm-lock.yaml

Lines changed: 11 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)