نموذج موضوع جديد، مثل قوالب GitHub Issue؟

يتوفر لدى Discourse حاليًا ميزة قوالب الفئات، والتي تملأ المُنشئ مسبقًا. إنها مفيدة، ولكن يمكن أن تكون خطوة رائعة إلى الأمام من ذلك هي القدرة على إنشاء نموذج موضوع جديد مخصص، مع حقول مخصصة، مدفوعًا بتعريف YAML، مثل التعريف الموجود لمشاكل GitHub.

لذا شيء مثل هذا…

name: Bug Report
description: File a bug report
title: "[Bug]: "
labels: ["bug", "triage"]
assignees:
  - octocat
body:
  - type: markdown
    attributes:
      value: |
        Thanks for taking the time to fill out this bug report!
  - type: input
    id: contact
    attributes:
      label: Contact Details
      description: How can we get in touch with you if we need more info?
      placeholder: ex. email@example.com
    validations:
      required: false
  - type: textarea
    id: what-happened
    attributes:
      label: What happened?
      description: Also tell us, what did you expect to happen?
      placeholder: Tell us what you see!
      value: "A bug happened!"
    validations:
      required: true
  - type: dropdown
    id: version
    attributes:
      label: Version
      description: What version of our software are you running?
      options:
        - 1.0.2 (Default)
        - 1.0.3 (Edge)
    validations:
      required: true
  - type: dropdown
    id: browsers
    attributes:
      label: What browsers are you seeing the problem on?
      multiple: true
      options:
        - Firefox
        - Chrome
        - Safari
        - Microsoft Edge
  - type: textarea
    id: logs
    attributes:
      label: Relevant log output
      description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
      render: shell
  - type: checkboxes
    id: terms
    attributes:
      label: Code of Conduct
      description: By submitting this issue, you agree to follow our [Code of Conduct](https://example.com)
      options:
        - label: I agree to follow this project's Code of Conduct
          required: true

يترجم إلى شيء مثل هذا…

نسخة أبسط بكثير من هذا تدعم نوع حقل واحد فقط (أي، مربع نص) ستظل تحسنًا جيدًا جدًا مقارنة بقوالب الفئات الحالية، على الرغم من ذلك!

إعجاب واحد (1)

يوجد هذا بالفعل، أي مساعدة؟:

إعجابَين (2)

ماذا عن إضافة Custom Wizard لهذا؟

إعجاب واحد (1)

في تجربتي، لا يُعد المكون الإضافي للمُعالج المخصص حلاً جيدًا لهذه الحالة الاستخدام. تفقد المعاينة، والنوافذ المنبثقة للمواضيع المقترحة، وبعض الأشياء الأخرى. سيكون الحل الأفضل هنا هو شيء يحل محل المُلحن جزئيًا مع الاحتفاظ بالتدفق والتجربة الإجمالية.

إعجاب واحد (1)

تحقق من Introducing Experimental Form Templates

إعجابَين (2)