2016-08-31 11:30:51 -04:00
|
|
|
import { registerUnbound } from 'discourse-common/lib/helpers';
|
2017-07-26 12:13:49 -04:00
|
|
|
import { renderIcon } from 'discourse-common/lib/icon-library';
|
2017-07-26 16:25:09 -04:00
|
|
|
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) {
|
|
|
|
return renderIcon('string', id, params);
|
2015-01-14 15:01:41 -05:00
|
|
|
}
|
|
|
|
|
2015-01-28 11:01:01 -05: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
|
|
|
});
|