Emancipation checklist page: convert case_emancipation.js to Stimulus + fetch
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 62/100
- Loại issue
- Tái cấu trúc
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- javascript, ruby
- Lĩnh vực
- frontend
Hướng nghiên cứu
Start by reading app/javascript/src/case_emancipation.js alongside the page it drives, app/views/emancipations/show.html.erb, and the existing controllers in app/javascript/controllers/ to see the Stimulus conventions. Port the checkbox save, category toggle and status reporting to a new emancipation_checklist_controller.js using fetch, then remove the old file and its require. Done means the system specs in spec/system/emancipations/show_spec.rb and spec/system/casa_cases/emancipation/show_spec.rb pass, npm run test passes with the rewritten tests/case_emancipations.test.js, and notifier.js is left in place for patch_notes.js.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
What
The emancipation checklist page for a case (app/views/emancipations/show.html.erb, at /casa_cases/:id/emancipation) is driven by app/javascript/src/case_emancipation.js. It's about 230 lines of jQuery: it saves each checkbox with $.post, expands and collapses categories, and reports save status through notifier.js. Convert it to a Stimulus controller that uses fetch.
Checklist
- Add
app/javascript/controllers/emancipation_checklist_controller.jswith the same behavior: check or uncheck a category or option saves right away, child options are shown or hidden, and errors are visible to the user - Replace the jQuery Notifier with the design-system flash (
shared/_flashes,alert_classes) or a small inline status. Note thatnotifier.jsis also used bypatch_notes.js, so don't delete it here - Delete
app/javascript/src/case_emancipation.jsand itsrequire. Rewrite__tests__/case_emancipations.test.js -
bundle exec rspec spec/system/emancipations/show_spec.rb spec/system/casa_cases/emancipation/show_spec.rbpasses
Before you start
- Comment here to be assigned. Setup is
bin/setup, thenbin/dev. Logins are in the README. - JS tests:
npm run test. Lint:bin/lint. - Part of #7301 (removing jQuery). Keep this PR to just this file.
- Ngôn ngữ chính
- Ruby
- Star
- 384
- Fork
- 558
- Merge trung bình
- 1 ngày 7 giờ
- Pull request đã merge (30 ngày)
- 63
Chuẩn bị môi trường
Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.
- Có Dockerfile hoặc tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của rubyforgood/casa
-
⛓️ Security Difficulty: Easy Good First Issue Help Wanted ruby Type: Bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
rubyforgood/casa#7404 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Difficulty: Easy Good First Issue Help Wanted ruby Type: Bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
rubyforgood/casa#7402 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Remove the bin/bundle binstub (Heroku warns it can break Bundler on deploy)Có thể đã có người làm @Akash-Dhanwate đã nhận 8 ngày trước. Đang mởdependencies Difficulty: Easy Good First Issue
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 82/100
rubyforgood/casa#7325 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Reports page: move export-button disable/re-enable into a Stimulus controllerCó thể làm lại được @Akash-Dhanwate đã nhận 9 ngày trước và không có pull request nào đang mở. Đang mởDifficulty: Easy Good First Issue Help Wanted javascript
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
rubyforgood/casa#7311 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
New case: use Stimulus for the "I don't know the court date yet" toggleCó thể làm lại được @Aryankn29 đã nhận 9 ngày trước và không có pull request nào đang mở. Đang mởDifficulty: Easy Good First Issue Help Wanted javascript
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
rubyforgood/casa#7310 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của rubyforgood/casa
Issue tương tự
-
enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
internetee/registry#2984 ·
Maintainer thường phản hồi trong vòng 6 ngày
-
Redis Lua error `@user_script:52: ERR value is not an integer or out of range` when `window_size` is configuredCó thể đã có người làm @mimosa đã nhận hôm nay. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
riscv/riscv-unified-db#2829 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
docker-library/ruby#534 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100