2018-06-15 11:03:24 -04:00
|
|
|
import { registerUnbound } from "discourse-common/lib/helpers";
|
|
|
|
import { renderIcon } from "discourse-common/lib/icon-library";
|
|
|
|
import deprecated from "discourse-common/lib/deprecated";
|
2015-01-28 11:01:01 -05:00
|
|
|
|
2017-07-26 12:13:49 -04:00
|
|
|
export function iconHTML(id, params) {
|
2018-06-15 11:03:24 -04:00
|
|
|
return renderIcon("string", id, params);
|
2015-01-14 15:01:41 -05:00
|
|
|
}
|
|
|
|
|
2018-06-15 11:03:24 -04:00
|
|
|
registerUnbound("fa-icon", function(icon, params) {
|
2017-07-26 16:25:09 -04:00
|
|
|
deprecated("Use `{{d-icon}}` instead of `{{fa-icon}}");
|
2015-02-24 13:47:46 -05:00
|
|
|
return new Handlebars.SafeString(iconHTML(icon, params));
|
2014-09-09 17:29:05 -04:00
|
|
|
});
|