dist/@ajsf/core/bundles/ajsf-core.umd.js
/**
     * 'addClasses' function
     *
     * Merges two space-delimited lists of CSS classes and removes duplicates.
     *
     * // {string | string[] | Set<string>} oldClasses
     * // {string | string[] | Set<string>} newClasses
     * // {string | string[] | Set<string>} - Combined classes
     */
'addClasses' function
Merges two space-delimited lists of CSS classes and removes duplicates.


' addClasses ' function Merges two space - delimited lists of CSS classes and removes duplicates .
function addClasses(oldClasses, newClasses) {
        var badType = function (i) { return !isSet(i) && !isArray(i) && !isString(i); };
        if (badType(newClasses)) {
            return oldClasses;
        }
        if (badType(oldClasses)) {
            oldClasses = '';
        }
        var toSet = function (i) { return isSet(i) ? i : isArray(i) ? new Set(i) : new Set(i.split(' ')); };
        var combinedSet = toSet(oldClasses);
        var newSet = toSet(newClasses);
        newSet.forEach(function (c) { return combinedSet.add(c); });
        if (isSet(oldClasses)) {
            return combinedSet;
        }
        if (isArray(oldClasses)) {
            return Array.from(combinedSet);
        }
        return Array.from(combinedSet).join(' ');
    }
function addClasses ( oldClasses , newClasses ) { var badType = function ( i ) { return ! isSet ( i ) && ! isArray ( i ) && ! isString ( i ) ; } ; if ( badType ( newClasses ) ) { return oldClasses ; } if ( badType ( oldClasses ) ) { oldClasses = '' ; } var toSet = function ( i ) { return isSet ( i ) ? i : isArray ( i ) ? new Set ( i ) : new Set ( i . split ( ' ' ) ) ; } ; var combinedSet = toSet ( oldClasses ) ; var newSet = toSet ( newClasses ) ; newSet . forEach ( function ( c ) { return combinedSet . add ( c ) ; } ) ; if ( isSet ( oldClasses ) ) { return combinedSet ; } if ( isArray ( oldClasses ) ) { return Array . from ( combinedSet ) ; } return Array . from ( combinedSet ) . join ( ' ' ) ; }
'addClasses' function
 Merges two space-delimited lists of CSS classes and removes duplicates.
' addClasses ' function Merges two space - delimited lists of CSS classes and removes duplicates .