Skip to content
This repository was archived by the owner on Feb 4, 2022. It is now read-only.

Conversation

@Komposten
Copy link
Member

@Komposten Komposten commented May 19, 2020

This PR adds a placeholder in the create post modal which indicates that media is being loaded. This appears after the user selects a media file but before the file has been processed (e.g. copied or converted) to indicate to the user that something is happening.

To accomplish this I've added an EventService which functions like an event bus. Different services and widgets can subscribe to events or post events. For example, the MediaService posts events to notify about its progress while OBSavePostModal subscribes to these media events in order to update the media attached to the post.

I implemented the event bus system myself since it was necessary that an event subscriber be able to "consume" the event and thus prevent it from being processed by other subscribers down the line. For example, both the OBHomePage and OBSavePostModal subscribe to share events, but if the modal is open the OBHomePage should not receive any of these events (since they're handled by the post modal).

This is a draft since there are a few bugs to iron out and I want to test a couple of variations on the visuals of the indicator.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants