Manual:Tags/ja

変更タグまたは版タグは、版や記録項目に関連付けられた注釈です. これらは、版に言及する際に、ページ履歴、差分表示、最近の更新など、さまざまな場所で表示されます.

利用できるタグの完全な一覧は Special:Tags に表示されます. Users with the   – administrators by default – can use this special page to create and delete tags. (See .)

Extensions (for example and ) mark edits made through their interface with tags.



タグ名
拡張機能でタグをハード コードする予定がある場合は、競合を避けるためにややユニークな名前を選ぶようにしてください. For example, VisualEditor uses,  ,. Tag names may not contain  or   characters.

If your extension allows users to enter their own tag names, you can use the function to validate those names. (There is no need to pass the optional parameter for this purpose.) この関数は、無効なタグ名や他の拡張機能やウィキの利用者によって既に予約されているタグ名を拒否します.

Make sure to register all tags your extension uses (whether hard-coded or user-supplied) by implementing the hook. If a tag is in active use (that is, it is not disabled), you should also list it via the hook.

If you wish to prevent users from creating certain tags, you can implement the hook. For example, the extension uses this hook to reserve all tags beginning with. (See source.)



拡張機能からのタグの使用
All tags used on at least one revision, and any tags listed by the hook, are shown on Special:Tags.

Each tag is known by a code name, which functions as its unique identifier. This code name is displayed on Special:Tags. Two messages are associated with each tag:


 * can be used to set the "display name" or "friendly name" of the tag. If set, this message will be used on history pages etc. instead of the tag's code name.
 * provides a description to be displayed on Special:Tags.

To add a tag to a revision, recent changes entry, or log entry, use. The hook can be useful for this purpose.



Special:Tags を拡張する
By default, tags defined by extensions cannot be manipulated from Special:Tags at all. All tag management tasks are left up to the extension.

If you wish, you can allow users to delete a tag defined by your extension from the regular Special:Tags interface. To do this, you must implement the hook to mark the tag as deletable, then implement the  hook to perform extension-specific cleanup actions after MediaWiki has removed the tag from all revisions and log entries to which it is applied.



コアの変更タグの一覧

 * : changing the content model
 * ,,  : turning a page into a redirect / a redirect into a normal page / changing where a redirect goes
 * : blanking the page
 * : changing more than 90% of the page text
 * ,,  : various kinds of reverts
 * : edit that got reverted
 * : file uploaded using maintenance script



関連項目

 * Documentation about Wikipedia tags
 * Extensions that define tags
 * Database tables: change_tag, valid_tag (removed), tag_summary (removed)
 * Magic word #tag (unrelated to the feature described on this page)

提案:


 * Revision tagging use cases like editing channels, see p/RevisionTags
 * On Phabricator