Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Multiple instructions show as one comma-joined paragraph ("questions., Conditional")

Đang mở Phù hợp với người mới
#1,812 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

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ó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
78/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
react, typescript
Lĩnh vực
frontend

Hướng nghiên cứu

Việc nối bằng dấu phẩy diễn ra trong packages/react-core/src/components/InstrumentOverview/InstrumentOverview.tsx ở dòng 51 và trong packages/react-core/src/components/FormContent/FormContent.tsx ở dòng 42. Hãy bắt đầu bằng cách đọc cả hai vị trí để xem instructions được hiển thị như thế nào, sau đó thay đổi từng nơi để hiển thị mỗi mục thành một phần tử riêng, chẳng hạn như một mục danh sách. Hoàn thành khi ví dụ trong hướng dẫn hiển thị hai dòng riêng biệt ở cả phần tổng quan lẫn hộp thoại hướng dẫn.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Area: Shared Bug Difficulty: Low Good First Issue Priority: Low

Problem

The instructions field is a string[] of "Brief sequential instructions":
https://github.com/DouglasNeuroInformatics/OpenDataCapture/blob/432dec8115722d8316922f0069f0c3b67f09214a/packages/runtime-core/src/types/instrument.base.ts#L49-L50

The instrument guidelines show each entry as one full sentence:
https://github.com/DouglasNeuroInformatics/OpenDataCapture/blob/432dec8115722d8316922f0069f0c3b67f09214a/packages/instrument-guidelines/AGENTS.md#L743-L744

en: ['Please answer all required questions.', 'Conditional questions will appear based on your answers.'],

But both renderers join the entries with ', ' into one paragraph:

Steps to reproduce

  1. Make an instrument with clientDetails.instructions set to the guidelines example above.
  2. Open the instrument overview, or open the instructions dialog in the form.

Expected

Each instruction shows as its own line or list item:

Please answer all required questions.
Conditional questions will appear based on your answers.

Actual

Please answer all required questions., Conditional questions will appear based on your answers.

Note

The instruments in instrument-library use only one entry, so they do not show the problem. Instruments that follow the documented example do show it.

Suggested fix

Render each entry as its own element in both components. For example, use an <ol>/<ul> (the entries are "sequential"), or one <p> for each entry. Do not use join(', ').

cc @thomasbeaudry (last change to these files)

Ngôn ngữ chính
TypeScript
Star
119
Fork
19
Merge trung bình
4 ngày 11 giờ
Pull request đã merge (30 ngày)
35

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của DouglasNeuroInformatics/OpenDataCapture

Tất cả issue của DouglasNeuroInformatics/OpenDataCapture

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.