mirror of
https://github.com/discourse/discourse.git
synced 2025-05-25 09:57:25 +08:00
DEV: fix some deprecated SVG icon refs
This commit is contained in:
@ -133,12 +133,20 @@ class PluginApi {
|
||||
*
|
||||
* // for the place in code that render a string
|
||||
* string() {
|
||||
* return "<i class='fa fa-smile-o'></i>";
|
||||
* return "<svg class=\"fa d-icon d-icon-far-smile svg-icon\" aria-hidden=\"true\"><use xlink:href=\"#far-smile\"></use></svg>";
|
||||
* },
|
||||
*
|
||||
* // for the places in code that render virtual dom elements
|
||||
* node() {
|
||||
* return h('i', { className: 'fa fa-smile-o' });
|
||||
* return h("svg", {
|
||||
* attributes: { class: "fa d-icon d-icon-far-smile", "aria-hidden": true },
|
||||
* namespace: "http://www.w3.org/2000/svg"
|
||||
* },[
|
||||
* h("use", {
|
||||
* "xlink:href": attributeHook("http://www.w3.org/1999/xlink", `#far-smile`),
|
||||
* namespace: "http://www.w3.org/2000/svg"
|
||||
* })]
|
||||
* );
|
||||
* }
|
||||
* });
|
||||
**/
|
||||
|
Reference in New Issue
Block a user