![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
htmx-ext-class-tools
Advanced tools
The `class-tools` extension allows you to specify CSS classes that will be swapped onto or off of the elements by using a `classes` or `data-classes` attribute. This functionality allows you to apply [CSS Transitions](https://developer.mozilla.org/en-US
The class-tools
extension allows you to specify CSS classes that will be swapped onto or off of the elements by using
a classes
or data-classes
attribute. This functionality allows you to apply
CSS Transitions
to your HTML without resorting to javascript.
A classes
attribute value consists of "runs", which are separated by an &
character. All
class operations within a given run will be applied sequentially, with the delay specified.
Within a run, a ,
character separates distinct class operations.
A class operation is an operation name add
, remove
, or toggle
, followed by a CSS class name,
optionally followed by a colon :
and a time delay.
<script src="https://unpkg.com/htmx-ext-class-tools@2.0.0/class-tools.js"></script>
<div hx-ext="class-tools">
<div classes="add foo"/> <!-- adds the class "foo" after 100ms -->
<div class="bar" classes="remove bar:1s"/> <!-- removes the class "bar" after 1s -->
<div class="bar" classes="remove bar:1s, add foo:1s"/> <!-- removes the class "bar" after 1s
then adds the class "foo" 1s after that -->
<div class="bar" classes="remove bar:1s & add foo:1s"/> <!-- removes the class "bar" and adds
class "foo" after 1s -->
<div classes="toggle foo:1s"/> <!-- toggles the class "foo" every 1s -->
</div>
FAQs
## Manipulate classes of an element (e.g. for CSS transitions)
We found that htmx-ext-class-tools demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.