"valid_elements" syntax for element removal when empty attributes needs example

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

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

評価

難易度
2/5
見積もり時間
半日
初心者へのやさしさ
45/100
issue の種類
ドキュメント
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
javascript
領域
documentation

調査の方向性

Start with the content-filtering documentation page at the linked valid_elements section and compare its current table with the syntax described in the issue. Document an example such as -span![!style] and clarify the control-character placement; consider the proposed grammar only if it fits the page. Done means the empty-element and required-attribute syntax can be understood without reading tinymce.js.

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

説明

bug

Documentation/Product Version
6.8.5

Links to Page(s) affected
https://www.tiny.cloud/docs/tinymce/latest/content-filtering/#valid_elements

Description of Issue

This entry:

"! - Enables removal of elements with no attributes such as . They can still have content though."

needs example, as I had to look into the code to find the "elementRuleRegExp" in tinymce.js and break it apart to figure out its' usage. Here, it needs to be something like "-span![!style]", the "!" in front of "[", whereas "!style" means a required attribute.

Suggested Fix
Adding the example with that comment would help.

Also, breaking this table up or adding a column to show what control characters can go where. Better than that, from that RegExp, having a template documented like BNF is far clearer (brief and incomplete, but you get the point):

=[","]
=["/"][]["[""]"]
= "+" | "-" | "#"
= "@" | "*" |
=
=
="" | "!"

主要言語
JavaScript
スター
96
フォーク
219
平均マージ
1日 4時間
マージ済み PR(30日)
26

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

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

はじめの一歩

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

tinymce/tinymce-docs のほかの issue

tinymce/tinymce-docs の issue をすべて見る

似ている issue

JavaScript の issue をもっと見る

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

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