UNPKG

@wordpress/editor

Version:
29 lines (27 loc) 693 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getTemplatePartIcon = getTemplatePartIcon; var _icons = require("@wordpress/icons"); /** * WordPress dependencies */ /** * Helper function to retrieve the corresponding icon by name. * * @param {string} iconName The name of the icon. * * @return {Object} The corresponding icon. */ function getTemplatePartIcon(iconName) { if ('header' === iconName) { return _icons.header; } else if ('footer' === iconName) { return _icons.footer; } else if ('sidebar' === iconName) { return _icons.sidebar; } return _icons.symbolFilled; } //# sourceMappingURL=get-template-part-icon.js.map