This module lets you rename and remove unused classes in Oxygen.
Note: The above video is for the plugin version before it was included as a module in Oxy Toolbox.
In the Oxygen editor, go to Manage > Selectors and click the c icon added by the plugin.
Enter the name of the class you wish to change sitewide in the left box and the new class name in the right box and press Rename button.
Do NOT prefix the class names with a dot.
Classes Cleaner will check all the pages/templates throughout the site looking for references to your existing class name and then replace all of them with the new class name that you specified.
Important: You must press Save for this to action to be completed.
Let’s say you add a class called button-red
to a Button component. You then decided that that is not quite the class you wanted to create or set for that element. You can un-assign that class from the component by pressing the x icon. This will only remove the class from the component but the class definition will continue to remain in Oxygen.
An unused class is a class that has not been applied to any element.
To scan, locate and delete one or more or all such unused classes simply click the “Scan For Un-Used Classes” button.
Classes Cleaner will scan the entire site and list the unused classes.
Once the results appear in the list, you can select individual classes by ctrl/cmd clicking or all of them by pressing ctrl/cmd + a and hitting the “Delete Selected” button.
Note: Classes Cleaner does not clean unused selectors directly added in the Selectors panel at Manage > Selectors.