inline-style-editor 1.3.6 → 1.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2056,7 +2056,12 @@ function listFonts() {
2056
2056
  while (!done) {
2057
2057
  const font = it.next();
2058
2058
  if (!font.done) {
2059
- arr.push(font.value[0].family);
2059
+ const value = font.value;
2060
+ let fontName;
2061
+ // webkit returns directly an object
2062
+ if (value.length) fontName = value[0].family;
2063
+ else fontName = value.family;
2064
+ arr.push(fontName);
2060
2065
  } else {
2061
2066
  done = font.done;
2062
2067
  }