MCPcopy Create free account
hub / github.com/textAngular/textAngular / recursiveRemoveClass

Function recursiveRemoveClass

src/textAngularSetup.js:745–752  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

743 // clear out all class attributes. These do not seem to be cleared via removeFormat
744 var $editor = this.$editor();
745 var recursiveRemoveClass = function(node){
746 node = angular.element(node);
747 /* istanbul ignore next: this is not triggered in tests any longer since we now never select the whole displayELement */
748 if(node[0] !== $editor.displayElements.text[0]) {
749 node.removeAttr('class');
750 }
751 angular.forEach(node.children(), recursiveRemoveClass);
752 };
753 angular.forEach(possibleNodes, recursiveRemoveClass);
754 // check if in list. If not in list then use formatBlock option
755 if(possibleNodes[0] && possibleNodes[0].tagName.toLowerCase() !== 'li' &&

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…