@mui/internal-code-infra 0.0.4-canary.10 → 0.0.4-canary.100

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (145) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +21 -7
  3. package/build/babel-config.d.mts +5 -1
  4. package/build/brokenLinksChecker/crawlWorker.d.mts +1 -0
  5. package/build/brokenLinksChecker/index.d.mts +192 -2
  6. package/build/changelog/fetchChangelogs.d.mts +3 -0
  7. package/build/changelog/types.d.ts +3 -1
  8. package/build/cli/cmdArgosPush.d.mts +8 -2
  9. package/build/cli/cmdBuild.d.mts +48 -2
  10. package/build/cli/cmdCopyFiles.d.mts +14 -2
  11. package/build/cli/cmdExtractErrorCodes.d.mts +2 -2
  12. package/build/cli/cmdGenerateChangelog.d.mts +17 -2
  13. package/build/cli/cmdGithubAuth.d.mts +2 -2
  14. package/build/cli/cmdListWorkspaces.d.mts +14 -2
  15. package/build/cli/cmdNetlifyIgnore.d.mts +12 -2
  16. package/build/cli/cmdPublish.d.mts +23 -4
  17. package/build/cli/cmdPublishCanary.d.mts +20 -2
  18. package/build/cli/cmdPublishNewPackage.d.mts +10 -2
  19. package/build/cli/cmdRenameScope.d.mts +18 -0
  20. package/build/cli/cmdSetVersionOverrides.d.mts +5 -2
  21. package/build/cli/cmdVale.d.mts +46 -0
  22. package/build/cli/cmdValidateBuiltTypes.d.mts +2 -2
  23. package/build/eslint/baseConfig.d.mts +3 -1
  24. package/build/eslint/mui/rules/disallow-react-api-in-server-components.d.mts +2 -2
  25. package/build/eslint/mui/rules/docgen-ignore-before-comment.d.mts +2 -2
  26. package/build/eslint/mui/rules/no-floating-cleanup.d.mts +5 -0
  27. package/build/eslint/mui/rules/no-guarded-throw.d.mts +31 -0
  28. package/build/eslint/mui/rules/no-presentation-role.d.mts +5 -0
  29. package/build/eslint/mui/rules/no-restricted-resolved-imports.d.mts +8 -2
  30. package/build/eslint/mui/rules/nodeEnvUtils.d.mts +18 -0
  31. package/build/remark/config.d.mts +43 -0
  32. package/build/remark/createLintTester.d.mts +10 -0
  33. package/build/remark/firstBlockHeading.d.mts +4 -0
  34. package/build/remark/gitDiff.d.mts +2 -0
  35. package/build/remark/noSpaceInLinks.d.mts +2 -0
  36. package/build/remark/straightQuotes.d.mts +2 -0
  37. package/build/remark/tableAlignment.d.mts +2 -0
  38. package/build/remark/terminalLanguage.d.mts +2 -0
  39. package/build/utils/babel.d.mts +7 -1
  40. package/build/utils/build.d.mts +59 -37
  41. package/build/utils/extractErrorCodes.d.mts +9 -0
  42. package/build/utils/git.d.mts +16 -0
  43. package/build/utils/github.d.mts +13 -1
  44. package/build/utils/pnpm.d.mts +176 -17
  45. package/build/utils/testUtils.d.mts +28 -0
  46. package/build/utils/typescript.d.mts +6 -16
  47. package/package.json +77 -53
  48. package/src/babel-config.mjs +3 -1
  49. package/src/brokenLinksChecker/crawlWorker.mjs +240 -0
  50. package/src/brokenLinksChecker/index.mjs +263 -188
  51. package/src/changelog/fetchChangelogs.mjs +8 -2
  52. package/src/changelog/renderChangelog.mjs +1 -1
  53. package/src/changelog/types.ts +3 -1
  54. package/src/cli/cmdBuild.mjs +51 -85
  55. package/src/cli/cmdListWorkspaces.mjs +7 -1
  56. package/src/cli/cmdNetlifyIgnore.mjs +30 -5
  57. package/src/cli/cmdPublish.mjs +79 -37
  58. package/src/cli/cmdPublishCanary.mjs +96 -24
  59. package/src/cli/cmdPublishNewPackage.mjs +31 -8
  60. package/src/cli/cmdRenameScope.mjs +76 -0
  61. package/src/cli/cmdSetVersionOverrides.mjs +8 -9
  62. package/src/cli/cmdVale.mjs +513 -0
  63. package/src/cli/index.mjs +4 -0
  64. package/src/cli/packageJson.d.ts +2 -3
  65. package/src/eslint/baseConfig.mjs +51 -19
  66. package/src/eslint/docsConfig.mjs +2 -1
  67. package/src/eslint/mui/config.mjs +24 -4
  68. package/src/eslint/mui/index.mjs +6 -0
  69. package/src/eslint/mui/rules/no-floating-cleanup.mjs +187 -0
  70. package/src/eslint/mui/rules/no-guarded-throw.mjs +115 -0
  71. package/src/eslint/mui/rules/no-presentation-role.mjs +60 -0
  72. package/src/eslint/mui/rules/nodeEnvUtils.mjs +52 -0
  73. package/src/eslint/mui/rules/require-dev-wrapper.mjs +25 -40
  74. package/src/estree-typescript.d.ts +1 -1
  75. package/src/remark/config.mjs +157 -0
  76. package/src/remark/createLintTester.mjs +19 -0
  77. package/src/remark/firstBlockHeading.mjs +87 -0
  78. package/src/remark/gitDiff.mjs +43 -0
  79. package/src/remark/noSpaceInLinks.mjs +42 -0
  80. package/src/remark/straightQuotes.mjs +31 -0
  81. package/src/remark/tableAlignment.mjs +23 -0
  82. package/src/remark/terminalLanguage.mjs +19 -0
  83. package/src/stylelint/index.mjs +2 -2
  84. package/src/untyped-plugins.d.ts +14 -14
  85. package/src/utils/build.mjs +604 -270
  86. package/src/utils/git.mjs +27 -7
  87. package/src/utils/pnpm.mjs +444 -53
  88. package/src/utils/testUtils.mjs +53 -0
  89. package/src/utils/typescript.mjs +23 -42
  90. package/vale/.vale.ini +1 -0
  91. package/vale/styles/MUI/CorrectReferenceAllCases.yml +42 -0
  92. package/vale/styles/MUI/CorrectRererenceCased.yml +14 -0
  93. package/vale/styles/MUI/GoogleLatin.yml +11 -0
  94. package/vale/styles/MUI/MuiBrandName.yml +22 -0
  95. package/vale/styles/MUI/NoBritish.yml +112 -0
  96. package/vale/styles/MUI/NoCompanyName.yml +17 -0
  97. package/build/markdownlint/duplicate-h1.d.mts +0 -56
  98. package/build/markdownlint/git-diff.d.mts +0 -11
  99. package/build/markdownlint/index.d.mts +0 -52
  100. package/build/markdownlint/straight-quotes.d.mts +0 -11
  101. package/build/markdownlint/table-alignment.d.mts +0 -11
  102. package/build/markdownlint/terminal-language.d.mts +0 -11
  103. package/src/brokenLinksChecker/__fixtures__/static-site/broken-links.html +0 -20
  104. package/src/brokenLinksChecker/__fixtures__/static-site/broken-targets.html +0 -22
  105. package/src/brokenLinksChecker/__fixtures__/static-site/example.md +0 -20
  106. package/src/brokenLinksChecker/__fixtures__/static-site/external-links.html +0 -21
  107. package/src/brokenLinksChecker/__fixtures__/static-site/ignored-page.html +0 -17
  108. package/src/brokenLinksChecker/__fixtures__/static-site/index.html +0 -28
  109. package/src/brokenLinksChecker/__fixtures__/static-site/known-targets.json +0 -5
  110. package/src/brokenLinksChecker/__fixtures__/static-site/nested/page.html +0 -21
  111. package/src/brokenLinksChecker/__fixtures__/static-site/orphaned-page.html +0 -20
  112. package/src/brokenLinksChecker/__fixtures__/static-site/page-with-api-links.html +0 -20
  113. package/src/brokenLinksChecker/__fixtures__/static-site/page-with-custom-targets.html +0 -24
  114. package/src/brokenLinksChecker/__fixtures__/static-site/page-with-ignored-content.html +0 -28
  115. package/src/brokenLinksChecker/__fixtures__/static-site/page-with-known-target-links.html +0 -19
  116. package/src/brokenLinksChecker/__fixtures__/static-site/unclosed-tags.html +0 -1
  117. package/src/brokenLinksChecker/__fixtures__/static-site/valid.html +0 -20
  118. package/src/brokenLinksChecker/__fixtures__/static-site/with-anchors.html +0 -31
  119. package/src/brokenLinksChecker/index.test.ts +0 -261
  120. package/src/changelog/categorizeCommits.test.ts +0 -319
  121. package/src/changelog/filterCommits.test.ts +0 -363
  122. package/src/changelog/parseCommitLabels.test.ts +0 -509
  123. package/src/changelog/renderChangelog.test.ts +0 -378
  124. package/src/changelog/sortSections.test.ts +0 -199
  125. package/src/eslint/mui/rules/add-undef-to-optional.test.mjs +0 -361
  126. package/src/eslint/mui/rules/consistent-production-guard.test.mjs +0 -162
  127. package/src/eslint/mui/rules/disallow-active-elements-as-key-event-target.test.mjs +0 -66
  128. package/src/eslint/mui/rules/disallow-react-api-in-server-components.test.mjs +0 -305
  129. package/src/eslint/mui/rules/docgen-ignore-before-comment.test.mjs +0 -52
  130. package/src/eslint/mui/rules/flatten-parentheses.test.mjs +0 -245
  131. package/src/eslint/mui/rules/mui-name-matches-component-name.test.mjs +0 -247
  132. package/src/eslint/mui/rules/no-empty-box.test.mjs +0 -40
  133. package/src/eslint/mui/rules/no-styled-box.test.mjs +0 -73
  134. package/src/eslint/mui/rules/require-dev-wrapper.test.mjs +0 -265
  135. package/src/eslint/mui/rules/rules-of-use-theme-variants.test.mjs +0 -149
  136. package/src/eslint/mui/rules/straight-quotes.test.mjs +0 -67
  137. package/src/markdownlint/duplicate-h1.mjs +0 -69
  138. package/src/markdownlint/git-diff.mjs +0 -31
  139. package/src/markdownlint/index.mjs +0 -62
  140. package/src/markdownlint/straight-quotes.mjs +0 -26
  141. package/src/markdownlint/table-alignment.mjs +0 -42
  142. package/src/markdownlint/terminal-language.mjs +0 -19
  143. package/src/utils/build.test.mjs +0 -705
  144. package/src/utils/template.test.mjs +0 -133
  145. package/src/utils/typescript.test.mjs +0 -380
package/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- The MIT License (MIT)
1
+ MIT License
2
2
 
3
3
  Copyright (c) 2019 Material-UI SAS
4
4
 
package/README.md CHANGED
@@ -37,22 +37,36 @@ This is stored in the `docs` top-level directory.
37
37
 
38
38
  Whenever new packages are added to the repo (that will get published to npm) or a private package is turned into a public one, follow the below steps before invoking the publish workflow of the previous section.
39
39
 
40
- 1. Goto your repo's code base on your system, open terminal and run:
40
+ > [!NOTE]
41
+ > This applies to packages published to npm, which is where Trusted Publishing needs the package to already exist. Packages that set `publishConfig.registry` to another registry are skipped by this check and need none of these steps.
42
+
43
+ 1. Go to your repo's code base on your system, then log in to npm using
44
+
45
+ ```bash
46
+ npm login
47
+ ```
48
+
49
+ 2. Once logged-in, open terminal and run:
41
50
 
42
51
  ```bash
43
52
  pnpm code-infra publish-new-package
44
53
  ```
45
54
 
46
55
  This command detects the new public packages in the repo and asks for your confirmation before publishing them to the npm registry. Add the `--dryRun` flag to skip the actual publishing.
56
+ If publishing fails with npm asking for `otp`, run the command again with 6 digit auth code from your authenticator app where you've added npm; Google Authenticator, Authy or similar:
57
+
58
+ ```bash
59
+ pnpm code-infra publish-new-package --otp=123456
60
+ ```
47
61
 
48
- 2. Goto the settings link for each packages, ie, https://www.npmjs.com/package/<pkg-name>/access , and setup `Trusted Publisher`.
49
- 3. In `Select your publisher` step in the above link, click on the `Github Actions` button to configure Github actions based trusted publishing.
50
- 4. Fill in the details of the repo -
62
+ 3. Go to the settings link for each package, e.g., `https://www.npmjs.com/package/<pkg-name>/access`, and setup `Trusted Publisher`.
63
+ 4. In the `Select your publisher` step in the above link, click on the `GitHub Actions` button to configure GitHub Actions-based trusted publishing.
64
+ 5. Fill in the details of the repo -
51
65
  1. `Organization or user` as `mui`,
52
66
  2. `Repository` as per the new package
53
67
  3. `Workflow filename*` should be `publish.yml`
54
- 4. `Environment name` should be `npm-publish`
55
- 5. In the `Publishing access` section, toggle the recommended option of `Require two-factor authentication and disallow tokens`.
56
- 6. Finally, save the changes by clicking on `Update Package Settings` button.
68
+ 4. `Environment name` should be `npm-publish` or `npm-publish-internal` based on whether the package is user facing package or internal package respectively.
69
+ 6. In the `Publishing access` section, toggle the recommended option of `Require two-factor authentication and disallow tokens`.
70
+ 7. Finally, save the changes by clicking on `Update Package Settings` button.
57
71
 
58
72
  After following these steps, the `Publish` workflow can be invoked again.
@@ -13,9 +13,10 @@ export type ReactCompilationMode = 'annotation' | 'syntax' | 'infer' | 'all';
13
13
  * @param {string} param0.runtimeVersion
14
14
  * @param {string} [param0.reactCompilerReactVersion]
15
15
  * @param {ReactCompilationMode} [param0.reactCompilerMode]
16
+ * @param {{ allowedCallees?: Record<string, string[]> }} [param0.displayName] - Options for the display name plugin.
16
17
  * @returns {import('@babel/core').TransformOptions} The base Babel configuration.
17
18
  */
18
- export declare function getBaseConfig({ debug, optimizeClsx, removePropTypes, noResolveImports, bundle, runtimeVersion, outExtension, reactCompilerReactVersion, reactCompilerMode }: {
19
+ export declare function getBaseConfig({ debug, optimizeClsx, removePropTypes, noResolveImports, bundle, runtimeVersion, outExtension, reactCompilerReactVersion, reactCompilerMode, displayName, }: {
19
20
  debug?: boolean;
20
21
  optimizeClsx?: boolean;
21
22
  removePropTypes?: boolean;
@@ -25,6 +26,9 @@ export declare function getBaseConfig({ debug, optimizeClsx, removePropTypes, no
25
26
  runtimeVersion: string;
26
27
  reactCompilerReactVersion?: string;
27
28
  reactCompilerMode?: ReactCompilationMode;
29
+ displayName?: {
30
+ allowedCallees?: Record<string, string[]>;
31
+ };
28
32
  }): import('@babel/core').TransformOptions;
29
33
  export type Options = {
30
34
  bundle?: 'esm' | 'cjs';
@@ -0,0 +1 @@
1
+ export {};
@@ -1,22 +1,103 @@
1
1
  export type LinkStructure = Map<string, Set<string>>;
2
2
  export type SerializedLinkStructure = {
3
+ /**
4
+ * - Object mapping page URLs to arrays of target IDs
5
+ */
3
6
  targets: Record<string, string[]>;
4
7
  };
8
+ export type CrawlWorkerInput = {
9
+ /**
10
+ * - The page URL to crawl
11
+ */
12
+ pageUrl: string;
13
+ /**
14
+ * - Fully resolved crawl options
15
+ */
16
+ options: ResolvedCrawlOptions;
17
+ };
18
+ export type CrawlWorkerPageData = {
19
+ /**
20
+ * - The normalized page URL
21
+ */
22
+ url: string;
23
+ /**
24
+ * - HTTP status code
25
+ */
26
+ status: number;
27
+ /**
28
+ * - Array of anchor targets (e.g., '#intro')
29
+ */
30
+ targets: string[];
31
+ /**
32
+ * - Content-type of the page
33
+ */
34
+ contentType: string;
35
+ };
36
+ export type CrawlWorkerOutput = {
37
+ /**
38
+ * - Serialized page data
39
+ */
40
+ pageData: CrawlWorkerPageData;
41
+ /**
42
+ * - Links discovered on the page
43
+ */
44
+ links: Link[];
45
+ /**
46
+ * - HTML validation results, or null if validation was skipped/passed
47
+ */
48
+ htmlValidateResults: {
49
+ pageUrl: string;
50
+ results: import('html-validate').Result[];
51
+ } | null;
52
+ };
5
53
  export type PageData = {
54
+ /**
55
+ * - The normalized page URL (without trailing slash unless root)
56
+ */
6
57
  url: string;
58
+ /**
59
+ * - HTTP status code from the response (e.g., 200, 404, 500)
60
+ */
7
61
  status: number;
62
+ /**
63
+ * - Set of available anchor targets on the page, keyed by hash (e.g., '#intro')
64
+ */
8
65
  targets: Set<string>;
66
+ /**
67
+ * - Content-type of the page (e.g., 'text/html', 'text/markdown')
68
+ */
9
69
  contentType: string;
10
70
  };
11
71
  export type Link = {
72
+ /**
73
+ * - URL of the page where this link was found, or null for seed URLs
74
+ */
12
75
  src: string | null;
76
+ /**
77
+ * - Accessible name/text content of the link element, or null for seed URLs
78
+ */
13
79
  text: string | null;
80
+ /**
81
+ * - The href attribute value (may be relative or absolute, with or without hash)
82
+ */
14
83
  href: string;
84
+ /**
85
+ * - Content-type of the source page (e.g., 'text/html', 'text/markdown')
86
+ */
15
87
  contentType?: string | null;
16
88
  };
17
89
  export type IgnoreRule = {
90
+ /**
91
+ * - Pattern(s) to match source page path
92
+ */
18
93
  path?: (string | RegExp) | (string | RegExp)[];
94
+ /**
95
+ * - Pattern(s) to match broken link href
96
+ */
19
97
  href?: (string | RegExp) | (string | RegExp)[];
98
+ /**
99
+ * - Pattern(s) to match source page content-type
100
+ */
20
101
  contentType?: (string | RegExp) | (string | RegExp)[];
21
102
  };
22
103
  export type NormalizedIgnoreRule = {
@@ -25,29 +106,138 @@ export type NormalizedIgnoreRule = {
25
106
  contentType: (string | RegExp)[] | undefined;
26
107
  };
27
108
  export type CrawlOptions = {
109
+ /**
110
+ * - Shell command to start the dev server (e.g., 'npm run dev'). If null, assumes server is already running
111
+ */
28
112
  startCommand?: string | null;
113
+ /**
114
+ * - Base URL of the site to crawl (e.g., 'http://localhost:3000')
115
+ */
29
116
  host: string;
117
+ /**
118
+ * - File path to write discovered link targets to. If null, targets are not persisted
119
+ */
30
120
  outPath?: string | null;
121
+ /**
122
+ * - Array of regex patterns to exclude from crawling (e.g., [/^\/api\//] to skip /api/* routes)
123
+ */
31
124
  ignoredPaths?: RegExp[];
125
+ /**
126
+ * - CSS selectors for elements whose nested links should be ignored (e.g., ['.sidebar', 'footer'])
127
+ */
32
128
  ignoredContent?: string[];
129
+ /**
130
+ * - Set of element IDs to ignore as link targets (defaults to '__next', '__NEXT_DATA__')
131
+ */
33
132
  ignoredTargets?: Set<string>;
133
+ /**
134
+ * - Pre-populated map of known valid targets to skip crawling (useful for external pages)
135
+ */
34
136
  knownTargets?: Map<string, Set<string>>;
137
+ /**
138
+ * - URLs to fetch known targets from (fetched JSON will be merged with knownTargets)
139
+ */
35
140
  knownTargetsDownloadUrl?: string[];
141
+ /**
142
+ * - Number of concurrent page fetches (defaults to 4)
143
+ */
36
144
  concurrency?: number;
145
+ /**
146
+ * - Starting URLs for the crawl (defaults to ['/'])
147
+ */
37
148
  seedUrls?: string[];
149
+ /**
150
+ * - Rules to ignore broken links. Each rule can have path, href, contentType, and/or has properties. All specified properties must match (AND logic). Within a property, multiple values use OR logic.
151
+ */
38
152
  ignores?: IgnoreRule[];
153
+ /**
154
+ * - Enable HTML validation on crawled pages. `false` (default): disabled. `true`: validate with recommended rules. Object: use as html-validate config — `mui:recommended` is always applied as the baseline, so most callers only need to set `rules`. Array: per-path config overrides — `mui:recommended` is applied once as the baseline and every entry whose `path` matches the page URL is layered on top; later matching entries win on conflicting rule keys. If an entry omits `extends`, it behaves like a rule patch and typically only changes the rules it names. If an entry includes `extends` (for example, re-extending `mui:recommended`), it can re-introduce or reset baseline presets rather than acting as a pure patch. An entry without `path` matches every page. If no entry matches, the page is not validated.
155
+ */
156
+ htmlValidate?: HtmlValidateOption;
157
+ /**
158
+ * - Log extra diagnostics during crawling (e.g. resolved html-validate config per page). Defaults to `false`.
159
+ */
160
+ verbose?: boolean;
39
161
  };
40
- export type ResolvedCrawlOptions = Omit<Required<CrawlOptions>, 'ignores'> & {
162
+ export type HtmlValidateOverride = {
163
+ /**
164
+ * - Pattern(s) to match the page URL. Strings use exact match. Omit to match every page.
165
+ */
166
+ path?: (string | RegExp) | (string | RegExp)[];
167
+ /**
168
+ * - html-validate config (or `true` for `mui:recommended`).
169
+ */
170
+ config: true | import('html-validate').ConfigData;
171
+ };
172
+ export type HtmlValidateOption = boolean | import('html-validate').ConfigData | HtmlValidateOverride[];
173
+ export type ResolvedHtmlValidateEntry = {
174
+ path: (string | RegExp)[] | undefined;
175
+ config: import('html-validate').ConfigData;
176
+ };
177
+ export type ResolvedCrawlOptions = Omit<Required<CrawlOptions>, 'ignores' | 'htmlValidate'> & {
41
178
  ignores: NormalizedIgnoreRule[];
179
+ htmlValidate: ResolvedHtmlValidateEntry[];
42
180
  };
43
- export type Issue = {
181
+ export type BrokenLinkIssue = {
182
+ /**
183
+ * - Type of issue: 'broken-link' for 404 pages, 'broken-target' for missing anchors
184
+ */
44
185
  type: 'broken-link' | 'broken-target';
186
+ /**
187
+ * - Human-readable description of the issue (e.g., 'Target not found', 'Page returned error 404')
188
+ */
45
189
  message: string;
190
+ /**
191
+ * - The link object that has the issue
192
+ */
46
193
  link: Link;
47
194
  };
195
+ export type HtmlValidateIssue = {
196
+ /**
197
+ * - Issue type discriminator
198
+ */
199
+ type: 'html-validate';
200
+ /**
201
+ * - Human-readable description of the issue
202
+ */
203
+ message: string;
204
+ /**
205
+ * - The page URL where the issue was found
206
+ */
207
+ pageUrl: string;
208
+ /**
209
+ * - The html-validate rule that triggered this issue (e.g., 'no-dup-id')
210
+ */
211
+ ruleId: string;
212
+ /**
213
+ * - Severity level (1 = warning, 2 = error)
214
+ */
215
+ severity: number;
216
+ /**
217
+ * - Source location of the issue
218
+ */
219
+ location: {
220
+ line: number;
221
+ column: number;
222
+ };
223
+ /**
224
+ * - DOM selector for the element, or null
225
+ */
226
+ selector: string | null;
227
+ };
228
+ export type Issue = BrokenLinkIssue | HtmlValidateIssue;
48
229
  export type CrawlResult = {
230
+ /**
231
+ * - All links discovered during the crawl
232
+ */
49
233
  links: Set<Link>;
234
+ /**
235
+ * - All pages crawled, keyed by normalized URL
236
+ */
50
237
  pages: Map<string, PageData>;
238
+ /**
239
+ * - All issues found (broken links, broken targets, and HTML validation issues)
240
+ */
51
241
  issues: Issue[];
52
242
  };
53
243
  /**
@@ -4,6 +4,9 @@ export type FetchCommitsOptions = {
4
4
  repo: string;
5
5
  lastRelease: string;
6
6
  release: string;
7
+ /**
8
+ * - GitHub organization name, defaults to 'mui'
9
+ */
7
10
  org?: string;
8
11
  };
9
12
  /**
@@ -13,6 +13,8 @@ export interface FetchedCommitDetails {
13
13
  } | null;
14
14
  mergedAt: string | null;
15
15
  createdAt: string | null;
16
+ prTitle: string;
17
+ prBody: string;
16
18
  }
17
19
  /**
18
20
  * Parsed label information from a commit.
@@ -212,7 +214,7 @@ export interface IntroConfig {
212
214
  * - {{teamCount}}: Number of team members
213
215
  * - {{communityCount}}: Number of community contributors
214
216
  *
215
- * Example: "We'd like to extend a big thank you to the {{contributorCount}} contributors who made this release possible"
217
+ * Example: "A big thanks to the {{contributorCount}} contributors who made this release possible."
216
218
  *
217
219
  * Set to `false` or omit to disable the thank you message.
218
220
  */
@@ -1,6 +1,12 @@
1
1
  #!/usr/bin/env node
2
2
  export type Args = {
3
+ /**
4
+ * - Run with verbose logging
5
+ */
3
6
  verbose?: boolean;
7
+ /**
8
+ * - Screenshots folder path
9
+ */
4
10
  folder: string;
5
11
  };
6
12
  /**
@@ -8,5 +14,5 @@ export type Args = {
8
14
  * @property {boolean} [verbose] - Run with verbose logging
9
15
  * @property {string} folder - Screenshots folder path
10
16
  */
11
- declare const _default: import("yargs").CommandModule<{}, Args>;
12
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
17
+ declare const _default: import('yargs').CommandModule<{}, Args>;
18
+ export default _default;
@@ -1,18 +1,64 @@
1
1
  export type Args = {
2
+ /**
3
+ * - The bundles to build.
4
+ */
2
5
  bundle: import('../utils/build.mjs').BundleType[];
6
+ /**
7
+ * - The large files to build.
8
+ */
3
9
  hasLargeFiles: boolean;
10
+ /**
11
+ * - Whether to skip generating a package.json file in the /esm folder.
12
+ */
4
13
  skipBundlePackageJson: boolean;
14
+ /**
15
+ * - Whether to enable verbose logging.
16
+ */
5
17
  verbose: boolean;
18
+ /**
19
+ * - Whether to build types for the package.
20
+ */
6
21
  buildTypes: boolean;
22
+ /**
23
+ * - Whether to build types for the package.
24
+ */
7
25
  skipTsc: boolean;
26
+ /**
27
+ * - Whether to skip checking for Babel runtime dependencies in the package.
28
+ */
8
29
  skipBabelRuntimeCheck: boolean;
30
+ /**
31
+ * - Whether to skip generating the package.json file in the bundle output.
32
+ */
9
33
  skipPackageJson: boolean;
34
+ /**
35
+ * - Whether to skip checking for main field in package.json.
36
+ */
10
37
  skipMainCheck: boolean;
38
+ /**
39
+ * - Globs to be ignored by Babel.
40
+ */
11
41
  ignore: string[];
42
+ /**
43
+ * - Files/Directories to be copied. Can be a glob pattern.
44
+ */
12
45
  copy?: string[];
46
+ /**
47
+ * - Whether to use the React compiler.
48
+ */
13
49
  enableReactCompiler?: boolean;
50
+ /**
51
+ * - Whether to build types using typescript native (tsgo).
52
+ */
14
53
  tsgo?: boolean;
54
+ /**
55
+ * - Deprecated no-op; flat builds are always used.
56
+ */
15
57
  flat?: boolean;
58
+ /**
59
+ * - Whether to enumerate glob patterns in exports/imports into concrete entries.
60
+ */
61
+ expand: boolean;
16
62
  };
17
- declare const _default: import("yargs").CommandModule<{}, Args>;
18
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
63
+ declare const _default: import('yargs').CommandModule<{}, Args>;
64
+ export default _default;
@@ -1,8 +1,20 @@
1
1
  export type Args = {
2
+ /**
3
+ * Run in silent mode without logging
4
+ */
2
5
  silent?: boolean;
6
+ /**
7
+ * Exclude default files from the copy operation
8
+ */
3
9
  excludeDefaults?: boolean;
10
+ /**
11
+ * Glob patterns to copy
12
+ */
4
13
  glob?: string[];
14
+ /**
15
+ * Extra files to copy
16
+ */
5
17
  files?: string[];
6
18
  };
7
- declare const _default: import("yargs").CommandModule<{}, Args>;
8
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
19
+ declare const _default: import('yargs').CommandModule<{}, Args>;
20
+ export default _default;
@@ -2,5 +2,5 @@ export type Args = import('../utils/extractErrorCodes.mjs').Args;
2
2
  /**
3
3
  * @typedef {import('../utils/extractErrorCodes.mjs').Args} Args
4
4
  */
5
- declare const _default: import("yargs").CommandModule<{}, import("../utils/extractErrorCodes.mjs").Args>;
6
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
5
+ declare const _default: import('yargs').CommandModule<{}, Args>;
6
+ export default _default;
@@ -1,8 +1,23 @@
1
1
  export type Args = {
2
+ /**
3
+ * Path to the changelog configuration file
4
+ */
2
5
  config: string;
6
+ /**
7
+ * The git reference (tag/commit) of the last release
8
+ */
3
9
  lastRelease: string;
10
+ /**
11
+ * The git reference (tag/commit) of the new release
12
+ */
4
13
  release: string;
14
+ /**
15
+ * The version number for the new release
16
+ */
5
17
  releaseVersion: string;
18
+ /**
19
+ * The current working directory to run the command in
20
+ */
6
21
  cwd: string;
7
22
  };
8
23
  /**
@@ -13,5 +28,5 @@ export type Args = {
13
28
  * @property {string} releaseVersion The version number for the new release
14
29
  * @property {string} cwd The current working directory to run the command in
15
30
  */
16
- declare const _default: import("yargs").CommandModule<{}, Args>;
17
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
31
+ declare const _default: import('yargs').CommandModule<{}, Args>;
32
+ export default _default;
@@ -7,5 +7,5 @@ export type Args = {
7
7
  * @property {boolean} authorize
8
8
  * @property {boolean} clear
9
9
  */
10
- declare const _default: import("yargs").CommandModule<{}, Args>;
11
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
10
+ declare const _default: import('yargs').CommandModule<{}, Args>;
11
+ export default _default;
@@ -1,9 +1,21 @@
1
1
  #!/usr/bin/env node
2
2
  export type PublicPackage = import('../utils/pnpm.mjs').PublicPackage;
3
3
  export type Args = {
4
+ /**
5
+ * - Whether to filter to only public packages
6
+ */
4
7
  publicOnly?: boolean;
8
+ /**
9
+ * - Output format (name, path, or json)
10
+ */
5
11
  output?: 'json' | 'path' | 'name' | 'publish-dir';
12
+ /**
13
+ * - Git reference to filter changes since
14
+ */
6
15
  sinceRef?: string;
16
+ /**
17
+ * - Same as filtering packages with --filter in pnpm. Only include packages matching the filter. See https://pnpm.io/filtering.
18
+ */
7
19
  filter?: string[];
8
20
  };
9
21
  /**
@@ -13,5 +25,5 @@ export type Args = {
13
25
  * @property {string} [sinceRef] - Git reference to filter changes since
14
26
  * @property {string[]} [filter] - Same as filtering packages with --filter in pnpm. Only include packages matching the filter. See https://pnpm.io/filtering.
15
27
  */
16
- declare const _default: import("yargs").CommandModule<{}, Args>;
17
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
28
+ declare const _default: import('yargs').CommandModule<{}, Args>;
29
+ export default _default;
@@ -1,7 +1,17 @@
1
1
  #!/usr/bin/env node
2
2
  export type Args = {
3
+ /**
4
+ * - List of workspace names to process
5
+ */
3
6
  workspaces: string[];
7
+ /**
8
+ * - Check mode - error if the generated content differs from current
9
+ */
4
10
  check?: boolean;
11
+ /**
12
+ * - Branch to compare PRs against (default: master)
13
+ */
14
+ baseBranch?: string;
5
15
  };
6
- declare const _default: import("yargs").CommandModule<{}, Args>;
7
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
16
+ declare const _default: import('yargs').CommandModule<{}, Args>;
17
+ export default _default;
@@ -1,13 +1,32 @@
1
1
  #!/usr/bin/env node
2
2
  export type PublicPackage = import('../utils/pnpm.mjs').PublicPackage;
3
3
  export type PublishOptions = import('../utils/pnpm.mjs').PublishOptions;
4
+ export type PublishSummaryEntry = import('../utils/pnpm.mjs').PublishSummaryEntry;
4
5
  export type Args = {
5
- dry-run: boolean;
6
- github-release: boolean;
6
+ /**
7
+ * Run in dry-run mode without publishing
8
+ */
9
+ "dry-run": boolean;
10
+ /**
11
+ * Create a GitHub draft release after publishing
12
+ */
13
+ "github-release": boolean;
14
+ /**
15
+ * NPM dist tag to publish to
16
+ */
7
17
  tag: string;
18
+ /**
19
+ * Runs in CI environment
20
+ */
8
21
  ci: boolean;
22
+ /**
23
+ * Git SHA to use for the GitHub release workflow (local only)
24
+ */
9
25
  sha?: string;
26
+ /**
27
+ * Same as filtering packages with --filter in pnpm. Only publish packages matching the filter. See https://pnpm.io/filtering.
28
+ */
10
29
  filter?: string[];
11
30
  };
12
- declare const _default: import("yargs").CommandModule<{}, Args>;
13
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
31
+ declare const _default: import('yargs').CommandModule<{}, Args>;
32
+ export default _default;
@@ -3,14 +3,32 @@ export type PublicPackage = import('../utils/pnpm.mjs').PublicPackage;
3
3
  export type VersionInfo = import('../utils/pnpm.mjs').VersionInfo;
4
4
  export type PublishOptions = import('../utils/pnpm.mjs').PublishOptions;
5
5
  export type Args = {
6
+ /**
7
+ * - Whether to run in dry-run mode
8
+ */
6
9
  dryRun?: boolean;
10
+ /**
11
+ * - Whether to create GitHub releases for canary packages
12
+ */
7
13
  githubRelease?: boolean;
14
+ /**
15
+ * - Same as filtering packages with --filter in pnpm. Only publish packages matching the filter. See https://pnpm.io/filtering.
16
+ */
8
17
  filter?: string[];
9
18
  };
10
19
  export type Commit = {
20
+ /**
21
+ * - Commit SHA
22
+ */
11
23
  sha: string;
24
+ /**
25
+ * - Commit message
26
+ */
12
27
  message: string;
28
+ /**
29
+ * - Commit author
30
+ */
13
31
  author: string;
14
32
  };
15
- declare const _default: import("yargs").CommandModule<{}, Args>;
16
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
33
+ declare const _default: import('yargs').CommandModule<{}, Args>;
34
+ export default _default;
@@ -1,9 +1,17 @@
1
1
  export type Args = {
2
+ /**
3
+ * If true, will only log the commands without executing them
4
+ */
2
5
  dryRun?: boolean;
6
+ /**
7
+ * 6 digit auth code to forward to npm for two-factor authentication
8
+ */
9
+ otp?: string;
3
10
  };
4
11
  /**
5
12
  * @typedef {Object} Args
6
13
  * @property {boolean} [dryRun] If true, will only log the commands without executing them
14
+ * @property {string} [otp] 6 digit auth code to forward to npm for two-factor authentication
7
15
  */
8
- declare const _default: import("yargs").CommandModule<{}, Args>;
9
- export default /** @type {import('yargs').CommandModule<{}, Args>} */ _default;
16
+ declare const _default: import('yargs').CommandModule<{}, Args>;
17
+ export default _default;
@@ -0,0 +1,18 @@
1
+ #!/usr/bin/env node
2
+ export type Args = {
3
+ /**
4
+ * Source and target scope
5
+ */
6
+ alias: [string, string];
7
+ };
8
+ /**
9
+ * @typedef {Object} Args
10
+ * @property {[string, string]} alias Source and target scope
11
+ */
12
+ /**
13
+ * @param {string} alias
14
+ * @returns {[string, string]}
15
+ */
16
+ export declare function parseAlias(alias: string): [string, string];
17
+ declare const _default: import('yargs').CommandModule<{}, Args>;
18
+ export default _default;