toggle-attribute
Syntax
toggle-attribute: (attribute) [force] [every (time)] [after (time)][, (attribute) [force] ...];
This follows the standard spec for the JavaScript equivalent, element.toggleAttribute (https://developer.mozilla.org/en-US/docs/Web/API/Element/toggleAttribute), with the additional ACSS benefits of event persistence, the ability to chain using a comma, delayed commands, etc.
time = Time in standard CSS time format, eg. 1s = 1 second, 250ms = 250 milliseconds.
attribute = An attribute name, like "disabled", "data-something", etc.
force = (Optional) [from the MDN docs:] A boolean value which has the following effects:
- if not specified at all, the toggle-attribute command "toggles" the attribute specified — removing it if it is present, or else adding it if it is not present.
- if true, the toggle-attribute command adds the attribute specified.
- if false, the toggle-attribute command removes the attribute specified.