From f9af21c378f905a026721890c40c587a9ea63154 Mon Sep 17 00:00:00 2001 From: Yihui Liao <44729383+yihuiliao@users.noreply.github.com> Date: Tue, 14 Oct 2025 11:11:17 -0700 Subject: [PATCH 1/3] chore: add cursor rule for release notes --- .cursor/rules/release-notes.mdc | 71 +++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 .cursor/rules/release-notes.mdc diff --git a/.cursor/rules/release-notes.mdc b/.cursor/rules/release-notes.mdc new file mode 100644 index 00000000000..12c7ba73ae4 --- /dev/null +++ b/.cursor/rules/release-notes.mdc @@ -0,0 +1,71 @@ +--- +description: Use when formatting commit messages for release notes +globs: +alwaysApply: false +--- + +Given a list of commit messages, follow the steps to process them. + +## Step 1: Categorize Commits + +Sort ALL commit messages into one of six main categories. The main categories are the following: +- Enhancements +- Fixes +- Documentation +- Under Construction +- To Be Categorized +- S2 + +### Categorization Rules: +Use the following keywords to determine the category: +| Keyword | Category | +|----------------------------|----------| +| feat | Enhancements| +| fix | Fixes | +| docs | Documentation | +| alpha, beta, rc | Under Construction +| chore, revert, bump, build | To Be Categorized | +| S2 | S2 | + +Each category name must be written as a Markdown H2 heading using ##. + +## Step 2: Rewrite commit messages + +Original format: Type (Scope): Summary of changes - [@username](link to username) - [PR](link to PR) +New Format: Summary of changes - [@username](link to username) - [PR](link to PR) + +### General Guidelines: +- Keep the summary as a single, grammatically correct sentence +- The message should be concise and easy to read +- Wrap any camelCase or code-like terms (e.g. onClick, onAction, isDisabled) in backticks (`) + - Do NOT use backticks for component names +- Replace specific terms: + - RAC -> React Aria + - V3 -> React Spectrum +- ALWAYS capitalize UI component names + - Example: + - toast -> Toast + - inline alert -> InlineAlert + +### Component Names to Capitalize: +Accordion, Autocomplete, Badge, Breadcrumbs, Buttons, Calendar, Checkbox, CheckboxGroup, Collections, ColorArea, ColorField, ColorPicker, ColorSlider, ColorSwatch, ColorSwatchPicker, ColorWheel, ComboBox, Date and Time, DateField, DatePicker, DateRangePicker, Dialog, Disclosure, DisclosureGroup, Drag and Drop, DropZone, FileTrigger, Form, InlineAlert, Link, Listbox, ListView, Menu, Meter, Modal, NotificationBadge, NumberField, Picker, ProgressBar, ProgressCircle, RadioGroup, RangeCalendar, SearchField, Select, Slider, StatusLight, Switch, Table, Tabs, TagGroup, TextArea, TextField, TimeField, Toast, ToggleButton, ToggleButtonGroup, Tooltip, Tree, Virtualizer. + + +## Step 3: Add Sub-headings + +Within the Enhancements, Fixes, and Under Construction categories, group commits by UI component under sub-headings. + +### Sub-heading rules: +- Use sub-headings ONLY for: + - Enhancements + - Fixes + - Under Construction +- Do NOT create sub-headings for: + - Documentation + - To Be Categorized + - S2 +- Sub-headings should be in alphabetical order +- Use "Miscellaneous" as a sub-heading for commits that do not belong to a specific component +- Each category can have its own Miscellaneous sub-heading +- Write sub-headings and commits as unordered lists using a hyphen (-) +- Do NOT bold the sub-heading text From 5a86d32e825cbcdb37c4f3892052cd8867559616 Mon Sep 17 00:00:00 2001 From: Yihui Liao <44729383+yihuiliao@users.noreply.github.com> Date: Wed, 15 Oct 2025 16:10:38 -0700 Subject: [PATCH 2/3] update cursor rules --- .cursor/rules/add-subheadings.mdc | 22 ++++++++ .cursor/rules/categorize-commits.mdc | 36 ++++++++++++ .cursor/rules/release-notes.mdc | 71 ------------------------ .cursor/rules/rewrite-commit-message.mdc | 27 +++++++++ 4 files changed, 85 insertions(+), 71 deletions(-) create mode 100644 .cursor/rules/add-subheadings.mdc create mode 100644 .cursor/rules/categorize-commits.mdc delete mode 100644 .cursor/rules/release-notes.mdc create mode 100644 .cursor/rules/rewrite-commit-message.mdc diff --git a/.cursor/rules/add-subheadings.mdc b/.cursor/rules/add-subheadings.mdc new file mode 100644 index 00000000000..2fd46a24013 --- /dev/null +++ b/.cursor/rules/add-subheadings.mdc @@ -0,0 +1,22 @@ +--- +alwaysApply: false +--- + +# Step 3: Add sub-headings + +Within the Enhancements, Fixes, and Under Construction categories, group commits by UI component under sub-headings. + +### Sub-heading rules: +- Use sub-headings ONLY for: + - Enhancements + - Fixes + - Under Construction +- Do NOT create sub-headings for: + - Documentation + - To Be Categorized + - S2 +- Sub-headings should be in alphabetical order +- Use "Miscellaneous" as a sub-heading for commits that do not belong to a specific component +- Each category can have its own Miscellaneous sub-heading +- Write sub-headings and commits as unordered lists using a hyphen (-) +- Do NOT bold the sub-heading text \ No newline at end of file diff --git a/.cursor/rules/categorize-commits.mdc b/.cursor/rules/categorize-commits.mdc new file mode 100644 index 00000000000..466190cfadf --- /dev/null +++ b/.cursor/rules/categorize-commits.mdc @@ -0,0 +1,36 @@ +--- +alwaysApply: false +--- + +# Step 1: Categorize commits + +Sort ALL commit messages into one of six main categories. The main categories are the following: +- Enhancements +- Fixes +- Documentation +- Under Construction +- To Be Categorized +- S2 + +Before categorizing commits into other groups, check whether each commit should be classified as “Under Construction.” +- Follow the steps below in order: + 1. Identify pre-release packages + - Use a command such as grep to scan the repository for package versions that include prerelease identifiers (e.g., alpha, beta, rc) + 2. Extract component keywords from commit messages + - Parse each commit message to identify possible component names + - Normalize these keywords (e.g., lowercase, remove punctuation) for easier comparison. + 3. Compare extracted keywords with pre-release packages + - If any keyword matches a package in the list, mark the commit as Under Construction. + 4. Check for explicit prerelease keywords in commit text + - If the commit message directly includes alpha, beta, or rc, classify it as Under Construction, regardless of package matches. + +Next, categorize the remaining commits not categorized as "Under Construction". Use the following keywords to determine the category: +| Keyword | Category | +|----------------------------|----------| +| feat | Enhancements| +| fix | Fixes | +| docs | Documentation | +| chore, revert, bump, build | To Be Categorized | +| S2 | S2 | + +Do not duplicate commits. In terms of priority, it should be Under Construction > S2 > To Be Categorized > Enhancements > Fixes > Documentation diff --git a/.cursor/rules/release-notes.mdc b/.cursor/rules/release-notes.mdc deleted file mode 100644 index 12c7ba73ae4..00000000000 --- a/.cursor/rules/release-notes.mdc +++ /dev/null @@ -1,71 +0,0 @@ ---- -description: Use when formatting commit messages for release notes -globs: -alwaysApply: false ---- - -Given a list of commit messages, follow the steps to process them. - -## Step 1: Categorize Commits - -Sort ALL commit messages into one of six main categories. The main categories are the following: -- Enhancements -- Fixes -- Documentation -- Under Construction -- To Be Categorized -- S2 - -### Categorization Rules: -Use the following keywords to determine the category: -| Keyword | Category | -|----------------------------|----------| -| feat | Enhancements| -| fix | Fixes | -| docs | Documentation | -| alpha, beta, rc | Under Construction -| chore, revert, bump, build | To Be Categorized | -| S2 | S2 | - -Each category name must be written as a Markdown H2 heading using ##. - -## Step 2: Rewrite commit messages - -Original format: Type (Scope): Summary of changes - [@username](link to username) - [PR](link to PR) -New Format: Summary of changes - [@username](link to username) - [PR](link to PR) - -### General Guidelines: -- Keep the summary as a single, grammatically correct sentence -- The message should be concise and easy to read -- Wrap any camelCase or code-like terms (e.g. onClick, onAction, isDisabled) in backticks (`) - - Do NOT use backticks for component names -- Replace specific terms: - - RAC -> React Aria - - V3 -> React Spectrum -- ALWAYS capitalize UI component names - - Example: - - toast -> Toast - - inline alert -> InlineAlert - -### Component Names to Capitalize: -Accordion, Autocomplete, Badge, Breadcrumbs, Buttons, Calendar, Checkbox, CheckboxGroup, Collections, ColorArea, ColorField, ColorPicker, ColorSlider, ColorSwatch, ColorSwatchPicker, ColorWheel, ComboBox, Date and Time, DateField, DatePicker, DateRangePicker, Dialog, Disclosure, DisclosureGroup, Drag and Drop, DropZone, FileTrigger, Form, InlineAlert, Link, Listbox, ListView, Menu, Meter, Modal, NotificationBadge, NumberField, Picker, ProgressBar, ProgressCircle, RadioGroup, RangeCalendar, SearchField, Select, Slider, StatusLight, Switch, Table, Tabs, TagGroup, TextArea, TextField, TimeField, Toast, ToggleButton, ToggleButtonGroup, Tooltip, Tree, Virtualizer. - - -## Step 3: Add Sub-headings - -Within the Enhancements, Fixes, and Under Construction categories, group commits by UI component under sub-headings. - -### Sub-heading rules: -- Use sub-headings ONLY for: - - Enhancements - - Fixes - - Under Construction -- Do NOT create sub-headings for: - - Documentation - - To Be Categorized - - S2 -- Sub-headings should be in alphabetical order -- Use "Miscellaneous" as a sub-heading for commits that do not belong to a specific component -- Each category can have its own Miscellaneous sub-heading -- Write sub-headings and commits as unordered lists using a hyphen (-) -- Do NOT bold the sub-heading text diff --git a/.cursor/rules/rewrite-commit-message.mdc b/.cursor/rules/rewrite-commit-message.mdc new file mode 100644 index 00000000000..dda4572eaca --- /dev/null +++ b/.cursor/rules/rewrite-commit-message.mdc @@ -0,0 +1,27 @@ +--- +alwaysApply: false +--- + +You are a expert technical writer for front-end development. + +# Step 2: Rewrite commit messages + +Original format: Type (Scope): Summary of changes - [@username](link to username) - [PR](link to PR) +New Format: Summary of changes - [@username](link to username) - [PR](link to PR) + +### General Guidelines: +- Keep the summary as a single, grammatically correct sentence +- Verbs should be first person present tense but do NOT include the subject (e.g. I) +- The message should be concise and easy to read +- Wrap any camelCase or code-like terms (e.g. onClick, onAction, isDisabled) in backticks (``) + - Do NOT use backticks for component names +- Replace specific terms: + - RAC -> React Aria + - V3 -> React Spectrum +- ALWAYS capitalize UI component names + - Example: + - toast -> Toast + - inline alert -> InlineAlert + +### Component Names to Capitalize: +Accordion, Autocomplete, Badge, Breadcrumbs, Buttons, Calendar, Checkbox, CheckboxGroup, Collections, ColorArea, ColorField, ColorPicker, ColorSlider, ColorSwatch, ColorSwatchPicker, ColorWheel, ComboBox, Date and Time, DateField, DatePicker, DateRangePicker, Dialog, Disclosure, DisclosureGroup, Drag and Drop, DropZone, FileTrigger, Form, InlineAlert, Link, Listbox, ListView, Menu, Meter, Modal, NotificationBadge, NumberField, Picker, ProgressBar, ProgressCircle, RadioGroup, RangeCalendar, SearchField, Select, Slider, StatusLight, Switch, Table, Tabs, TagGroup, TextArea, TextField, TimeField, Toast, ToggleButton, ToggleButtonGroup, Tooltip, Tree, Virtualizer. \ No newline at end of file From daa241d36b33003a5c014c08729de452abb383ac Mon Sep 17 00:00:00 2001 From: Yihui Liao <44729383+yihuiliao@users.noreply.github.com> Date: Wed, 15 Oct 2025 16:12:47 -0700 Subject: [PATCH 3/3] add space --- .cursor/rules/add-subheadings.mdc | 2 +- .cursor/rules/rewrite-commit-message.mdc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.cursor/rules/add-subheadings.mdc b/.cursor/rules/add-subheadings.mdc index 2fd46a24013..d723ca3dfd5 100644 --- a/.cursor/rules/add-subheadings.mdc +++ b/.cursor/rules/add-subheadings.mdc @@ -19,4 +19,4 @@ Within the Enhancements, Fixes, and Under Construction categories, group commits - Use "Miscellaneous" as a sub-heading for commits that do not belong to a specific component - Each category can have its own Miscellaneous sub-heading - Write sub-headings and commits as unordered lists using a hyphen (-) -- Do NOT bold the sub-heading text \ No newline at end of file +- Do NOT bold the sub-heading text diff --git a/.cursor/rules/rewrite-commit-message.mdc b/.cursor/rules/rewrite-commit-message.mdc index dda4572eaca..a2d68af8858 100644 --- a/.cursor/rules/rewrite-commit-message.mdc +++ b/.cursor/rules/rewrite-commit-message.mdc @@ -24,4 +24,4 @@ New Format: Summary of changes - [@username](link to username) - [PR](link to PR - inline alert -> InlineAlert ### Component Names to Capitalize: -Accordion, Autocomplete, Badge, Breadcrumbs, Buttons, Calendar, Checkbox, CheckboxGroup, Collections, ColorArea, ColorField, ColorPicker, ColorSlider, ColorSwatch, ColorSwatchPicker, ColorWheel, ComboBox, Date and Time, DateField, DatePicker, DateRangePicker, Dialog, Disclosure, DisclosureGroup, Drag and Drop, DropZone, FileTrigger, Form, InlineAlert, Link, Listbox, ListView, Menu, Meter, Modal, NotificationBadge, NumberField, Picker, ProgressBar, ProgressCircle, RadioGroup, RangeCalendar, SearchField, Select, Slider, StatusLight, Switch, Table, Tabs, TagGroup, TextArea, TextField, TimeField, Toast, ToggleButton, ToggleButtonGroup, Tooltip, Tree, Virtualizer. \ No newline at end of file +Accordion, Autocomplete, Badge, Breadcrumbs, Buttons, Calendar, Checkbox, CheckboxGroup, Collections, ColorArea, ColorField, ColorPicker, ColorSlider, ColorSwatch, ColorSwatchPicker, ColorWheel, ComboBox, Date and Time, DateField, DatePicker, DateRangePicker, Dialog, Disclosure, DisclosureGroup, Drag and Drop, DropZone, FileTrigger, Form, InlineAlert, Link, Listbox, ListView, Menu, Meter, Modal, NotificationBadge, NumberField, Picker, ProgressBar, ProgressCircle, RadioGroup, RangeCalendar, SearchField, Select, Slider, StatusLight, Switch, Table, Tabs, TagGroup, TextArea, TextField, TimeField, Toast, ToggleButton, ToggleButtonGroup, Tooltip, Tree, Virtualizer.