Skip to content

Turn micro-button into Action #125

Description

@noyainrain

Unfortunately, customized built-in elements did not receive cross browser support over the years.

Draft:

/**
 * Action that runs when an element is activated.
 *
 * While the action is running, the element is suspended, i.e. it shows a progress indicator and is
 * not clickable.
 *
 * .. attribute:: element
 *
 *    Related :class:`Element`.
 *
 * .. attribute:: f
 *
 *    Function that performs the action. May be async.
 *
 * .. attribute:: args
 *
 *    Arguments passed to :attr:`f`, if any.
 *
 * .. attribute:: running
 *
 *    Indicates if the action is running.
 *
 * .. describe: .micro-suspended
 *
 *    Indicates if the element is suspended.
 */
micro.core.Action = class {
    /** Run the action. */
    async run() {}
};

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions