From 82e1f1e3b2c83e00ba2bf0776b4601571d6e6237 Mon Sep 17 00:00:00 2001 From: Nightt <87569709+nightt5879@users.noreply.github.com> Date: Mon, 3 Aug 2026 18:17:39 +0800 Subject: [PATCH 1/4] docs: add contribution guidelines and pull request template --- .github/pull_request_template.md | 37 ++++++++++++++++++ CONTRIBUTING.md | 67 ++++++++++++++++++++++++++++++++ 2 files changed, 104 insertions(+) create mode 100644 .github/pull_request_template.md create mode 100644 CONTRIBUTING.md diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 00000000..191b8c25 --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,37 @@ +## Summary + + + +## Related Issue + + + +## Validation + +- [ ] Applicable checks pass: lint, format check, tests, and build +- [ ] Relevant E2E and manual tests are complete or not applicable + +Evidence, screenshots, or compatibility notes: + + + +## AI Assistance + +Did you use AI tools to generate or substantially modify code, tests, or documentation in this pull request? + +- [ ] No +- [ ] Yes + +If yes: + +- **Tool/model:** +- **AI-assisted work:** +- **Human validation:** + +- [ ] I reviewed and understand the AI-assisted changes and can explain and maintain them + +## Checklist + +- [ ] The title and description are in English, and the change is focused +- [ ] I reviewed and understand every submitted change +- [ ] Tests, documentation, and translations were updated when needed diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..fcca47d1 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,67 @@ +# Contributing to Drawnix + +Thank you for contributing. Bug fixes, tests, documentation, translations, performance improvements, and focused features are welcome. + +## Community Language + +Drawnix uses English for issues, pull requests, discussions, reviews, commit messages, and contributor documentation. Localized product content is welcome, but contribution discussions should remain in English. + +## Before You Start + +- Search existing issues and discussions first. +- Reproduce bugs on the latest `develop` branch. +- Keep each issue or pull request focused on one problem. +- Discuss large features, architecture changes, or `.drawnix` format changes before implementation. +- Verify AI-assisted findings. Do not publish raw AI audit output or batches of unverified issues. + +## Local Development + +Use the Node.js version in `.nvmrc`. + +```bash +npm ci +npm run start +``` + +Before opening a pull request, run the checks that apply to your change: + +```bash +npm run lint +npm run format:check +npm run test +npm run build +``` + +For interaction changes, install the Playwright browsers and run the E2E tests: + +```bash +npx playwright install +npx nx e2e web-e2e +``` + +## Pull Requests + +- Target the `develop` branch. +- Use an English title, description, and clear commit messages. +- Explain what changed and why; link the related issue when available. +- Add or update tests for behavior changes. +- Include screenshots or a recording for visible UI changes. +- Update documentation and translations when needed. +- Preserve compatibility with existing `.drawnix` files when changing import, export, clipboard, or serialization behavior. +- Avoid unrelated formatting, refactoring, or dependency changes. + +## AI-Assisted Contributions + +AI tools are welcome, but contributors remain responsible for their work. If AI generated or substantially modified code, tests, or documentation, disclose: + +- The tool and model, if known +- What the AI helped with +- Your human review and testing + +You must understand, explain, and maintain the submitted changes. Raw or unverified AI output is not acceptable. Trivial autocomplete, spelling, and formatting assistance do not require disclosure. + +Do not provide secrets, private vulnerability details, personal data, or unauthorized content to external AI services. + +## License + +By contributing, you agree that your contribution will be licensed under the repository's MIT License. From 08d03de8c2f878a8e1fe74c60e328c67b3037928 Mon Sep 17 00:00:00 2001 From: Nightt <87569709+nightt5879@users.noreply.github.com> Date: Mon, 3 Aug 2026 18:22:18 +0800 Subject: [PATCH 2/4] docs: specify AI model in pull request example --- .github/pull_request_template.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 191b8c25..f9b3ffaf 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -24,7 +24,7 @@ Did you use AI tools to generate or substantially modify code, tests, or documen If yes: -- **Tool/model:** +- **Tool/model:** - **AI-assisted work:** - **Human validation:** From 82f272ca8ef29001a40754d42a991238326142cc Mon Sep 17 00:00:00 2001 From: Nightt <87569709+nightt5879@users.noreply.github.com> Date: Mon, 3 Aug 2026 18:23:54 +0800 Subject: [PATCH 3/4] docs: use first-person AI validation wording --- .github/pull_request_template.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index f9b3ffaf..9400503b 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -26,7 +26,7 @@ If yes: - **Tool/model:** - **AI-assisted work:** -- **Human validation:** +- **My review and validation:** - [ ] I reviewed and understand the AI-assisted changes and can explain and maintain them From 5669329e4724669e085cbde81cdcbe85ab9a0472 Mon Sep 17 00:00:00 2001 From: Nightt <87569709+nightt5879@users.noreply.github.com> Date: Wed, 5 Aug 2026 14:09:46 +0800 Subject: [PATCH 4/4] docs: link contribution guide from readmes --- README.md | 4 +++- README_en.md | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index ca66b155..e081786a 100644 --- a/README.md +++ b/README.md @@ -126,6 +126,8 @@ docker pull pubuzhixing/drawnix:latest 欢迎任何形式的贡献: +提交 Issue 或 Pull Request 前,请先阅读 [贡献指南](CONTRIBUTING.md)。 + - 提 Bug - 贡献代码 @@ -142,4 +144,4 @@ docker pull pubuzhixing/drawnix:latest ## License -[MIT License](https://github.com/plait-board/drawnix/blob/master/LICENSE) \ No newline at end of file +[MIT License](https://github.com/plait-board/drawnix/blob/master/LICENSE) diff --git a/README_en.md b/README_en.md index 29d4c50c..4215e3be 100644 --- a/README_en.md +++ b/README_en.md @@ -123,6 +123,8 @@ docker pull pubuzhixing/drawnix:latest Any form of contribution is welcome: +Before opening an issue or pull request, please read the [Contributing Guide](CONTRIBUTING.md). + - Report bugs - Contribute code @@ -139,4 +141,4 @@ Special thanks to the company for its strong support for open source projects, a ## License -[MIT License](https://github.com/plait-board/drawnix/blob/master/LICENSE) \ No newline at end of file +[MIT License](https://github.com/plait-board/drawnix/blob/master/LICENSE)