1
0
mirror of https://github.com/dwaxweiler/connector-mobilizon synced 2025-06-05 21:59:25 +02:00

use loading indicator

This commit is contained in:
Daniel Waxweiler
2022-06-05 21:22:34 +02:00
parent 513ee84d48
commit b3e9034ada
6 changed files with 78 additions and 50 deletions

View File

@ -1,3 +1,4 @@
/* eslint-disable @wordpress/i18n-ellipsis */
import { loadEventLists } from '../../events-loader.js'
const { InspectorControls } = wp.blockEditor
@ -55,17 +56,20 @@ export default ({ attributes, setAttributes }) => {
/>
</PanelBody>
</InspectorControls>,
<ul
<div
className={NAME + '_events-list'}
data-maximum={attributes.eventsCount}
data-group-name={attributes.groupName}
>
<li style={{ display: 'none' }}>
<div style={{ display: 'none' }}>
{__('The events could not be loaded!', '<wordpress-name>')}
</li>
<li style={{ display: 'none' }}>
</div>
<div style={{ display: 'none' }}>
{__('The group could not be found!', '<wordpress-name>')}
</li>
</ul>,
</div>
<ul>
<li>{__('Loading...', '<wordpress-name>')}</li>
</ul>
</div>,
]
}