set cssClass(val) {
    let attr = val;
    let newCl = [];
    // @TODO replace with clone utils method
    const prevClasses = [].concat(this.state.cssClass);

    if (Array.isArray(val)) {
      newCl = val;
      attr = val.join(' ');
    } else if (typeof val === 'string' && val.length) {
      newCl = val.split(' ');
    }

    this.state.cssClass = newCl;
    if (newCl.length) {
      this.setAttribute(attributes.CSS_CLASS, attr.toString());
    } else {
      this.removeAttribute(attributes.CSS_CLASS);
    }

    // Remove/Set CSS classes on the actual inner Button component
    const buttonCl = this.button.classList;
    const buttonClArr = Array.from(buttonCl);
    prevClasses.forEach((cssClass) => {
      if (!newCl.includes(cssClass)) {
        buttonCl.remove(cssClass);
      }
    });
    newCl.forEach((newCssClass) => {
      if (!buttonClArr.includes(newCssClass)) {
        buttonCl.add(newCssClass);
      }
    });
  }
/**
   * @param {Array|string} val containing CSS classes that will be applied to the button
   * Strings will be split into an array and separated by whitespace.
   */
@param {Array|string} val containing CSS classes that will be applied to the button
Strings will be split into an array and separated by whitespace.
@param { Array|string } val containing CSS classes that will be applied to the button Strings will be split into an array and separated by whitespace .
set cssClass(val) {
    let attr = val;
    let newCl = [];
    const prevClasses = [].concat(this.state.cssClass);
    if (Array.isArray(val)) {
      newCl = val;
      attr = val.join(' ');
    } else if (typeof val === 'string' && val.length) {
      newCl = val.split(' ');
    }
    this.state.cssClass = newCl;
    if (newCl.length) {
      this.setAttribute(attributes.CSS_CLASS, attr.toString());
    } else {
      this.removeAttribute(attributes.CSS_CLASS);
    }
    const buttonCl = this.button.classList;
    const buttonClArr = Array.from(buttonCl);
    prevClasses.forEach((cssClass) => {
      if (!newCl.includes(cssClass)) {
        buttonCl.remove(cssClass);
      }
    });
    newCl.forEach((newCssClass) => {
      if (!buttonClArr.includes(newCssClass)) {
        buttonCl.add(newCssClass);
      }
    });
  }
set cssClass ( val ) { let attr = val ; let newCl = [ ] ; const prevClasses = [ ] . concat ( this . state . cssClass ) ; if ( Array . isArray ( val ) ) { newCl = val ; attr = val . join ( ' ' ) ; } else if ( typeof val === 'string' && val . length ) { newCl = val . split ( ' ' ) ; } this . state . cssClass = newCl ; if ( newCl . length ) { this . setAttribute ( attributes . CSS_CLASS , attr . toString ( ) ) ; } else { this . removeAttribute ( attributes . CSS_CLASS ) ; } const buttonCl = this . button . classList ; const buttonClArr = Array . from ( buttonCl ) ; prevClasses . forEach ( ( cssClass ) => { if ( ! newCl . includes ( cssClass ) ) { buttonCl . remove ( cssClass ) ; } } ) ; newCl . forEach ( ( newCssClass ) => { if ( ! buttonClArr . includes ( newCssClass ) ) { buttonCl . add ( newCssClass ) ; } } ) ; }
@param {Array|string} val containing CSS classes that will be applied to the button
 Strings will be split into an array and separated by whitespace.
@param { Array|string } val containing CSS classes that will be applied to the button Strings will be split into an array and separated by whitespace .
// @TODO replace with clone utils method // Remove/Set CSS classes on the actual inner Button component