_consumeCssProperties(text) {
    /** @type {Array} */
    let m = null;
    // loop over text until all mixins with defintions have been applied
    while((m = MIXIN_MATCH.exec(text))) {
      let matchText = m[0];
      let mixinName = m[1];
      let idx = m.index;
      // collect properties before apply to be "defaults" if mixin might override them
      // match includes a "prefix", so find the start and end positions of @apply
      let applyPos = idx + matchText.indexOf('@apply');
      let afterApplyPos = idx + matchText.length;
      // find props defined before this @apply
      let textBeforeApply = text.slice(0, applyPos);
      let textAfterApply = text.slice(afterApplyPos);
      let defaults = this._cssTextToMap(textBeforeApply);
      let replacement = this._atApplyToCssProperties(mixinName, defaults);
      // use regex match position to replace mixin, keep linear processing time
      text = `${textBeforeApply}${replacement}${textAfterApply}`;
      // move regex search to _after_ replacement
      MIXIN_MATCH.lastIndex = idx + replacement.length;
    }
    return text;
  }
/**
   * replace mixin consumption with variable consumption
   * @param {string} text
   * @return {string}
   */
replace mixin consumption with variable consumption
@param {string} text
@return {string}
replace mixin consumption with variable consumption @param { string } text @return { string }
_consumeCssProperties(text) {
    let m = null;
    while((m = MIXIN_MATCH.exec(text))) {
      let matchText = m[0];
      let mixinName = m[1];
      let idx = m.index;
      let applyPos = idx + matchText.indexOf('@apply');
      let afterApplyPos = idx + matchText.length;
      let textBeforeApply = text.slice(0, applyPos);
      let textAfterApply = text.slice(afterApplyPos);
      let defaults = this._cssTextToMap(textBeforeApply);
      let replacement = this._atApplyToCssProperties(mixinName, defaults);
      text = `${textBeforeApply}${replacement}${textAfterApply}`;
      MIXIN_MATCH.lastIndex = idx + replacement.length;
    }
    return text;
  }
_consumeCssProperties ( text ) { let m = null ; while ( ( m = MIXIN_MATCH . exec ( text ) ) ) { let matchText = m [ 0 ] ; let mixinName = m [ 1 ] ; let idx = m . index ; let applyPos = idx + matchText . indexOf ( '@apply' ) ; let afterApplyPos = idx + matchText . length ; let textBeforeApply = text . slice ( 0 , applyPos ) ; let textAfterApply = text . slice ( afterApplyPos ) ; let defaults = this . _cssTextToMap ( textBeforeApply ) ; let replacement = this . _atApplyToCssProperties ( mixinName , defaults ) ; text = ` ${ textBeforeApply } ${ replacement } ${ textAfterApply } ` ; MIXIN_MATCH . lastIndex = idx + replacement . length ; } return text ; }
replace mixin consumption with variable consumption
 @param {string} text
 @return {string}
replace mixin consumption with variable consumption @param { string } text @return { string }
/** @type {Array} */ // loop over text until all mixins with defintions have been applied // collect properties before apply to be "defaults" if mixin might override them // match includes a "prefix", so find the start and end positions of @apply // find props defined before this @apply // use regex match position to replace mixin, keep linear processing time // move regex search to _after_ replacement