Communitygithub.com

コメントとディスカッションシステム

スレッド会話のための体系的なフレームワークを設計・実装し、ネスト深度、アクション階層、コミュニティシグナリングを管理することで、エンゲージメントと可読性を高めます。

コメントとディスカッションシステム とは?

このスキルは、複雑なマルチユーザーディスカッションを整理し、可読性とナビゲーションを向上させるための「コメントとディスカッションシステム」を設計・実装するための包括的なガイドです。コミュニティフォーラム、ブログコメント、SaaSコラボレーション、サポートQ&A、ソーシャルフィードなど、多様なユースケースに対応します。スレッドのネスト深度制限、アクションの優先順位付け(Reply、Vote、Edit、Report)、投稿者へのシグナリング(Author/Staffバッジ、未読マーク)、モバイル対応のレスポンシブ適応戦略など、具体的なルールとワークフローを提供します。また、無限ネストによる「字下げ死」やアクション過多によるアイコン氾濫など、よくある失敗パターンとその回避策についても解説しており、高品質なディスカッションUXの構築を支援します。

対応~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/coastdigitalgroup/coastai-skills/tree/HEAD/website-design/comment-and-discussion-system

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

コメントとディスカッションシステム は何をしますか?

目的

コメントとディスカッションシステムは、インタラクティブな会話レイヤーを設計するための方法論を提供します。これにより、複雑で多人数の対話が読みやすく、ナビゲートしやすく、整理された状態を保つことができます。スレッド、ネスト制限、アクションの優先順位、投稿者へのシグナリングに関するルールを定義することで、このシステムは「情報スパゲッティ」を防止し、高ボリューム環境でユーザーが最も価値のある投稿を見つけるのに役立ちます。

ユースケース

  • コミュニティフォーラム: ニッチなコミュニティ向けのスレッドディスカッションの設計。
  • 記事・ブログコメント: 長文コンテンツに対する読者フィードバックの有効化。
  • SaaSコラボレーション: プロジェクトタスク、ドキュメント、プルリクエスト内での内部ディスカッションの構造化。
  • サポートQ&A: 顧客の質問とスタッフの回答の整理。
  • ソーシャルフィード: 共有投稿やメディア上のインタラクションの管理。

使用すべきでないケース

  • ダイレクトメッセージ(チャット): リアルタイムの1対1または少人数グループメッセージングには、「メッセージバブル」とインスタント配信に最適化されたレイアウトを使用してください。
  • お知らせ専用フィード: ユーザーが返信やインタラクションできない場合、単純な通知リストで十分です。
  • 低インタラクションページ: ページに合計3件未満のコメントしか期待されない場合、スレッド化しないフラットリストの方が効率的です。
  • トランザクションログ: 自動化されたシステム監査ログには、timeline-activity-system を使用してください。

入力

  1. 階層モデル: スレッドはどこまで深くなるか?(フラット、ネスト、またはハイブリッド)
  2. ユーザー識別データ: アバター、表示名、ロール(例: モデレーター、著者、スタッフ)。
  3. エンゲージメント指標: 投票数(賛成/反対)、返信数、タイムスタンプ。
  4. コンテキストメタデータ: 「購入済み」、「トップ投稿者」、または「著者」バッジ。

出力

  1. コメント構造仕様: 単一のコメント「ノード」の視覚的定義(アバター、メタ情報、本文、アクション)。
  2. スレッディング設計図: ネストのための空間ルール(インデント増分と垂直な「スレッドライン」を含む)。
  3. アクション階層マップ: 「返信」、「投票」、「編集」、「報告」の優先順位付け。
  4. レスポンシブ適応戦略: モバイルでスレッドを折りたたんだり、レイアウトをフラット化したりするためのルール。

ワークフロー

1. コメント構造を定義する

一貫した「ノード」構造を確立します:

  • ヘッダー: ユーザーアバター(ネストレベルに応じたサイズ)、表示名、ロールバッジ、相対タイムスタンプ(例: 「2時間前」)。
  • 本文: テキストコンテンツ。必要に応じてマークダウンやリッチテキストをサポート。
  • アクションバー: プライマリアクション(返信、投票)とセカンダリアクション(共有、報告、編集)。

2. スレッドとネストのルールを確立する

返信間の空間的関係を管理します:

  • インデント: 一貫した増分(例: 24px または 1.5rem)をネストされた返信に使用します。
  • スレッドライン: 微妙な垂直線(幅1px)を使用して、返信をその親に視覚的にリンクします。
  • ネスト制限: スレッドをフラット化するか、「このスレッドを続ける」リンクで新しいビューに遷移する前に、最大深度(通常3~5レベル)を設定します。

3. アクションの優先順位をランク付けする

すべてのアクションが同じ重要度ではありません。視覚的な重みでユーザーを導きます:

  • プライマリ: 「返信」と「投票」はすぐに表示されるべきです。
  • セカンダリ: 「共有」や「リンク」はテキストのみ、またはアイコンのみで構いません。
  • オーバーフロー: 「編集」、「削除」、「報告」は「その他」(三点リーダー)メニュー内に配置して、乱雑さを減らします。

4. シグナリングと信頼を実装する

コンテキストを提供するために視覚的な手がかりを使用します:

  • 著者/スタッフのハイライト: 元の著者または公式スタッフに対して、異なる背景色や目立つバッジを使用します。
  • 新着/ハイライトされたコメント: 微妙な背景フェードまたは左ボーダーのアクセントを使用して、未読または新しく投稿されたコメントを通知します。
  • 投票の可視化: アクティブな場合にのみ色(例: 賛成票はオレンジ、反対票は青)を使用します。

5. レスポンシブ適応を計画する

スレッドは急速に水平スペースを消費します。狭いビューポートに適応します:

  • モバイルでのフラット化: モバイルではインデント増分を減らす(例: 24px から 8px)、またはネストをフラットになる前に2レベルに制限します。
  • 「フルスクリーン」ピボット: 深いスレッドの場合、返信をタップして、その返信と子返信を専用の全幅「フォーカスモード」で開くことを許可します。

判断ルール

  • インデント vs フラット: 「発見」(親のコンテキストが重要な場合)にはインデントを使用します。「タスク」環境(最新情報が優先される場合)には、@mention 参照付きのフラットリストを使用します。
  • 投票表示: コミュニティが「自主規制」を必要とする場合にのみ反対票を表示します。ほとんどのポジティブな成長環境では、賛成票のみを表示します。
  • デフォルトの並び順: コミュニティではデフォルトで「トップ」(加重スコア)にしますが、時間に敏感なコラボレーションツールでは「最新」にします。
  • 切り詰めルール: 非常に長いコメント(500語を超える)は、「もっと読む」ボタンで切り詰め、スレッドの垂直リズムを維持します。

制約

  • アクセシビリティ: コメントはキーボードでナビゲート可能である必要があります(Tabキーでアクション間を移動)。セマンティックHTMLを使用します(コメントには <article>、ネストには <ul>/<li>)。すべてのアクションには明確なラベルが必要です。「スレッドライン」は純粋に装飾的であるか(ARIAから隠す)、aria-hidden="true" を使用します。
  • レスポンシブ性: インデントによってコンテンツが画面の端からはみ出してはいけません。コンテナには padding-left または margin-left を使用し、ネストされたブロックに固定幅を使用しないでください。
  • パフォーマンス: 高ボリュームのスレッド(100コメント以上)では、「遅延読み込み」または「もっと読み込む」ページネーションを使用して、初期レンダリング時間が長くなるのを防ぎます。

よくある失敗パターン

  • 字下げ死: テキストが画面右側で1文字幅になるまで無限にネストを許可してしまうこと。
  • アクション過多: すべてのコメントの下に10個以上のボタンを表示し、「アイコンの海」を作り出してしまうこと。
  • 見えない階層: 「著者」と一般のコメント投稿者を区別できず、公式な回答を見つけるのが困難になること。
  • 「迷子の親」: スレッドラインのない深いスレッドにより、どの返信がどの親に属するかを追跡するのが困難になること。
  • 状態の欠落: ユーザーがコメントを送信したときに、「保留中」または「送信中」の状態が表示されないこと。

検証基準

  • ネスト深度が制限されており、フラットビューまたは「フォーカス」ビューに移行すること。
  • 視覚的階層が著者、スタッフ、一般ユーザーを区別していること。
  • スレッドラインが返信を親コメントに明確に接続していること。
  • プライマリアクション(返信/投票)がセカンダリアクションよりも視覚的に目立つこと。
  • インデントがモバイルビューポートに適応し、水平方向のオーバーフローを防ぐこと。
  • コメントがセマンティックにネストされたリストまたは記事としてマークアップされていること。
  • アクションボタンの最小タッチターゲットサイズが44x44ピクセルであること。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for progressive disclosure using accordions, ensuring structural integrity, visual affordances, and accessibility across different content densities and devices.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for long-form content, managing readability, vertical rhythm, and information density to ensure a superior reading experience.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for informational elements that communicate state (Badges) and categorization (Tags) with clarity and accessibility.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for non-overlay notifications, managing global announcements and contextual inline alerts to communicate system states without interrupting the user's flow.

coastdigitalgroup/coastai-skills

Design and implement a systematic, asymmetrical bento-grid layout framework to organize diverse content types cohesively while maintaining strict visual hierarchy, logical focus order, and responsive flexibility.

coastdigitalgroup/coastai-skills

Design a responsive, mobile-first bottom navigation bar and persistent action dock system for mobile websites and web applications, establishing spatial anchors, tab bar anatomy, badge indicators, thumb-zone ergonomics, safe area inset handling, active/inactive state contrast, and desktop responsive adaptation rules.

coastdigitalgroup/coastai-skills

Design a mobile-first bottom sheet overlay system with configurable detents, drag affordances, safe area padding, responsive desktop modal/popover adaptation, and WCAG AA accessibility compliance.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for secondary navigation trails that provide orientation, context, and one-click access to parent levels in deep information architectures.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for buttons and interactive triggers, managing visual hierarchy, variant logic, and action grouping to ensure clear intent and accessible interaction.

coastdigitalgroup/coastai-skills

Design a systematic framework for date and time selection, managing calendar grids, range pickers, and scheduling interfaces to ensure precision and accessibility.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for modular content containers that maintain hierarchy, structural integrity, and action alignment across variable content and responsive viewports.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for horizontal discovery components, managing navigation affordances, scroll behavior, and accessibility to ensure effective content density without compromising usability.

coastdigitalgroup/coastai-skills

Design a systematic, highly accessible, and developer-friendly UI layout framework for code blocks, snippet showcases, multi-file code tabs, line-highlighting, diff views, and syntax token contrast in technical documentation and developer platforms.

coastdigitalgroup/coastai-skills

Design a systematic framework for global command menus (Cmd+K panels) that combines keyboard-driven navigation, command execution, and shortcut discovery into an accessible, responsive overlay.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for side-by-side comparison interfaces, managing high attribute density and responsive complexity to support informed decision-making.

coastdigitalgroup/coastai-skills

Design and implement a systematic framework for user privacy, managing consent banners, preference centers, and persistent privacy controls to balance legal compliance with user trust.

coastdigitalgroup/coastai-skills

Design and implement a systematic, highly accessible, and responsive visual layout framework for conversational chat widgets, live chat boxes, and chatbot panels that ensures clear message scannability, native focus flow, and seamless mobile keyboard adaptation.

coastdigitalgroup/coastai-skills

Design a systematic, accessible, and high-conversion framework for custom select dropdowns and comboboxes, defining anatomy, states, search-filtering, and responsive mobile-adaptive patterns.

coastdigitalgroup/coastai-skills

Design and specify a systematic dark theme framework, establishing rules for elevation-based surface colors, desaturated brand accents, text legibility, and media adaptation to ensure an accessible, low-fatigue experience.

coastdigitalgroup/coastai-skills

Design and implement a systematic color palette that ensures WCAG 2.2 accessibility compliance. Trigger this skill when asked to define brand colors, create UI themes, or establish a visual system for a website.

関連スキル