popcodeorg / popcodeorg/popcode

<h1> within <p> causes following closing tags to turn red

オープン
#2,517 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

主要言語
JavaScript
スター
191
フォーク
143
平均マージ
4日 11時間
マージ済み PR(30日)
5

説明

Describe the bug
Putting an <h1> tag inside of a <p> tag causes the following closing tags to turn red.

To Reproduce
Steps to reproduce the behavior:

  1. Go to popcode.org
  2. Add the following HTML:
<!DOCTYPE html>
<html>
    <head>
        <title>Funfunctionality</title>
    </head>
    <body>
        <div class="webname">
            <p>
            	<h1>Funfunctionality</h1>
            </p>
        </div>
    </body>
</html>
  1. Notice color of closing tags

Expected behavior
Since Popcode is an opinionated editor, I'd recommend an error message like:
You can't put <h1> / <h2> etc header tags inside of a paragraph element. Put them before or after the <p> tag.

Screenshots
image

Notice that the page renders; Popcode does not detect any errors.

Desktop (please complete the following information):

  • OS: MacOS
  • Browser Firefox & Chrome
  • Version Latest

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

まず、提供された HTML を使って popcode.org で問題を再現し、その後、段落要素内にネストされた見出し要素をエディターがどのように処理するかと、既存のエラーまたはハイライトの挙動を追跡します。無効なネストがエディターの独自の方針に基づく挙動と一貫して処理され、閉じタグが誤解を招く形で赤くならなくなれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
html, javascript
領域
frontend, web-dev
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
55/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。