UNPKG

1.67 kBJavaScriptView Raw
1import { createElement } from "@wordpress/element";
2
3/**
4 * WordPress dependencies
5 */
6import { __ } from '@wordpress/i18n';
7import { Path, Rect, SVG } from '@wordpress/components';
8/**
9 * Internal dependencies
10 */
11
12import edit from './edit';
13export var name = 'core/latest-posts';
14export var settings = {
15 title: __('Latest Posts'),
16 description: __('Display a list of your most recent posts.'),
17 icon: createElement(SVG, {
18 viewBox: "0 0 24 24",
19 xmlns: "http://www.w3.org/2000/svg"
20 }, createElement(Path, {
21 d: "M0,0h24v24H0V0z",
22 fill: "none"
23 }), createElement(Rect, {
24 x: "11",
25 y: "7",
26 width: "6",
27 height: "2"
28 }), createElement(Rect, {
29 x: "11",
30 y: "11",
31 width: "6",
32 height: "2"
33 }), createElement(Rect, {
34 x: "11",
35 y: "15",
36 width: "6",
37 height: "2"
38 }), createElement(Rect, {
39 x: "7",
40 y: "7",
41 width: "2",
42 height: "2"
43 }), createElement(Rect, {
44 x: "7",
45 y: "11",
46 width: "2",
47 height: "2"
48 }), createElement(Rect, {
49 x: "7",
50 y: "15",
51 width: "2",
52 height: "2"
53 }), createElement(Path, {
54 d: "M20.1,3H3.9C3.4,3,3,3.4,3,3.9v16.2C3,20.5,3.4,21,3.9,21h16.2c0.4,0,0.9-0.5,0.9-0.9V3.9C21,3.4,20.5,3,20.1,3z M19,19H5V5h14V19z"
55 })),
56 category: 'widgets',
57 keywords: [__('recent posts')],
58 supports: {
59 html: false
60 },
61 getEditWrapperProps: function getEditWrapperProps(attributes) {
62 var align = attributes.align;
63
64 if (['left', 'center', 'right', 'wide', 'full'].includes(align)) {
65 return {
66 'data-align': align
67 };
68 }
69 },
70 edit: edit,
71 save: function save() {
72 return null;
73 }
74};
75//# sourceMappingURL=index.js.map
\No newline at end of file