Hima Art Utility

WordPressサイトに必要と思われる機能を満載した完全無料のオールインワンプラグインです

SVG画像挿入ショートコードの使い方

WordPress7.1で追加されたアイコンブロックですが、現段階では文章の中にインラインで挿入したり、テーブル内のセルに挿入したりすることはできません。

本ショートコードを使うことで、それらの場所にもWordPressコアで追加されたSVGアイコンや、任意にwp_register_icon_collection()とwp_register_icon()で追加したアイコンもこのショートコードで表示させることができるようになります。

本機能はHima Art Utilityのバージョン6.2以降で使用可能です

本機能は「追加コンテンツ」→「ショートコード」タブ→「HA Utilityショートコードを使う」を有効にすると使用できるようになり、ブロックツールバーからも簡単に挿入できるようになります。

ショートコードとパラメーター

以下がショートコードとパラメーターの役割です。

[ha-svg-icon-sc space="" slug="" class="" size="" label=""]
パラメーター役割デフォルト
(未指定または省略時)
spaceSVGアイコンのグループ
wp_register_icon_collection()の第一引数で指定した文字列
core
(WordPress標準のSVG)
slugアイコンのスラグ(コアはこちらで調べられます)
wp_register_icon()の第一引数で指定した文字列
class追加するCSSクラス
sizeアイコンの大きさ24
(ピクセル単位の数字のみ)
labelスクリーンリーダーで読み上げる際の文字列
(未指定の場合「aria-hidden=”true” と focusable=”false”」が付与されます)

WordPress標準のSVGアイコン一覧

以下のアイコン一覧から「core」に〇がついているものは本ショートコードで表示できます。

ショートコード挿入後「SVGアイコン」に表示している文字列をショートコードの「slug」パラメーターへ入れてください。

※アイコンスラグの左に実際のアイコンを表示しています

※「core-admin」グループのみ〇の付いているアイコンは管理画面専用なのでここでは表示されません

※「core」グループのみ〇の付いているアイコンは表示画面専用なので管理画面では利用できません

アイコンの一覧は2026年11月10日現在のものです。現在使用できるアイコンについてはこちらのGitHub上のソースを参考にしてください。

core-admincoreSVGアイコンダッシュアイコン
〇〇 arrow-downdashicons-arrow-down-alt
〇 arrow-down-left
〇 arrow-down-right
〇〇 arrow-leftdashicons-arrow-left-alt
〇〇 arrow-rightdashicons-arrow-right-alt
〇〇 arrow-updashicons-arrow-up-alt
〇 arrow-up-left
〇 arrow-up-right
〇asteriskdashicons-marker
〇 at-symbol
〇〇 audiodashicons-format-audio
〇〇 belldashicons-bell
〇〇 block-defaultdashicons-block-default
〇 block-meta
〇 block-table
〇brushdashicons-admin-appearance
〇〇 calendar
dashicons-calendar-alt
dashicons-calendar
〇〇 capture-photo
dashicons-camera
dashicons-camera-alt
〇〇 capture-video
dashicons-video-alt2
dashicons-video-alt
〇〇 cartdashicons-cart
〇〇 categorydashicons-category
〇〇 cautiondashicons-warning
〇〇 chart-bardashicons-chart-bar
〇〇 checkdashicons-yes
〇〇 chevron-downdashicons-arrow-down-alt2
〇〇 chevron-down-smalldashicons-arrow-down
〇〇 chevron-left
dashicons-admin-collapse
dashicons-arrow-left-alt2
〇〇 chevron-left-smalldashicons-arrow-left
〇〇 chevron-rightdashicons-arrow-right-alt2
〇〇 chevron-right-smalldashicons-arrow-right
〇〇 chevron-updashicons-arrow-up-alt2
〇 chevron-up-down
〇〇 chevron-up-smalldashicons-arrow-up
〇〇 commentdashicons-admin-comments
〇〇 cover
〇 create
〇dashboard
〇〇 desktopdashicons-desktop
〇〇 downloaddashicons-download
〇 drawer-left
〇 drawer-right
〇〇 envelope

dashicons-email
dashicons-email-alt
dashicons-email-alt2
〇〇 errordashicons-dismiss
〇〇 externaldashicons-external
〇file
〇〇 gallerydashicons-format-gallery
〇group
〇〇 headingdashicons-heading
〇〇 helpdashicons-editor-help
〇〇 homedashicons-admin-home
〇〇 imagedashicons-format-image
〇〇 info
dashicons-info
dashicons-info-outline
〇〇 keydashicons-admin-network
〇〇 languagedashicons-translation
〇link
dashicons-admin-links
dashicons-format-links
〇〇 map-marker
dashicons-location
dashicons-location-alt
〇mediadashicons-admin-media
〇〇 menu


dashicons-menu-alt
dashicons-menu
dashicons-menu-alt2
dashicons-menu-alt3
〇〇 mobiledashicons-smartphone
〇〇 more-horizontaldashicons-ellipsis
〇 more-vertical
〇〇 nextdashicons-controls-forward
〇pagedashicons-admin-page
〇〇 paragraphdashicons-editor-paragraph
〇〇 payment
〇〇 pencil
dashicons-edit
dashicons-edit-large
〇〇 people
dashicons-admin-users
dashicons-groups
〇pin
dashicons-admin-post
dashicons-format-standard
〇pluginsdashicons-admin-plugins
〇〇 plus
dashicons-plus
dashicons-plus-alt2
〇〇 plus-circledashicons-plus-alt
〇〇post-commentsdashicons-format-chat
〇〇 previousdashicons-controls-back
〇〇 publisheddashicons-yes-alt
〇〇 quote
dashicons-format-quote
dashicons-editor-quote
〇〇 receipt
〇〇 rssdashicons-rss
〇 scheduled
〇〇 searchdashicons-search
〇〇 settingsdashicons-admin-settings
〇 shadow
〇〇 share
dashicons-share
dashicons-share1
〇〇 shield
dashicons-shield
dashicons-shield-alt
〇〇 shuffledashicons-randomize
〇sitesdashicons-admin-multisite
〇〇 star-emptydashicons-star-empty
〇〇 star-filleddashicons-star-filled
〇〇 star-halfdashicons-star-half
〇〇 storedashicons-store
〇 styles
〇 symbol
〇 symbol-filled
〇〇 tabledashicons-editor-table
〇〇 tabletdashicons-tablet
〇〇 tagdashicons-tag
〇〇 tipdashicons-lightbulb
〇tooldashicons-admin-tools
〇update
dashicons-update
dashicons-update-alt
〇〇 uploaddashicons-upload
〇 verse
〇wordpressdashicons-wordpress

バージョン6.0以降をお使いの方は、プラグイン一覧画面に更新情報が表示されますので、そこから更新を行ってください

最新バージョン 6.1 (2026年 5月21日リリース)

累計ダウンロード数:1回

コメントを残す

メールアドレスが公開されることはありません。 ※ が付いている欄は必須項目です

※リンクやURLの挿入されているコメントは無視します