UNPKG

@wordpress/block-library

Version:
54 lines (52 loc) 1.53 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _i18n = require("@wordpress/i18n"); var _icons = require("@wordpress/icons"); /** * WordPress dependencies */ const variations = [{ name: 'post-date', title: (0, _i18n.__)('Post Date'), description: (0, _i18n.__)("Display a post's publish date."), attributes: { metadata: { bindings: { datetime: { source: 'core/post-data', args: { key: 'date' } } } } }, scope: ['block', 'inserter', 'transform'], isActive: blockAttributes => blockAttributes?.metadata?.bindings?.datetime?.source === 'core/post-data' && blockAttributes?.metadata?.bindings?.datetime?.args?.key === 'date', icon: _icons.postDate }, { name: 'post-date-modified', title: (0, _i18n.__)('Modified Date'), description: (0, _i18n.__)("Display a post's last updated date."), attributes: { metadata: { bindings: { datetime: { source: 'core/post-data', args: { key: 'modified' } } } }, className: 'wp-block-post-date__modified-date' }, scope: ['block', 'inserter', 'transform'], isActive: blockAttributes => blockAttributes?.metadata?.bindings?.datetime?.source === 'core/post-data' && blockAttributes?.metadata?.bindings?.datetime?.args?.key === 'modified', icon: _icons.postDate }]; var _default = exports.default = variations; //# sourceMappingURL=variations.js.map