locize 4.0.14 → 4.0.15

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.
package/locize.js CHANGED
@@ -396,7 +396,7 @@
396
396
  }
397
397
  function getElementNamespace(el) {
398
398
  var found;
399
- var find = function find(ele) {
399
+ var _find = function find(ele) {
400
400
  var opts = getAttribute(ele, 'i18next-options');
401
401
  if (!opts) opts = getAttribute(ele, 'data-i18next-options');
402
402
  if (!opts) opts = getAttribute(ele, 'i18n-options');
@@ -412,9 +412,9 @@
412
412
  if (!found) found = getAttribute(ele, 'data-i18next-ns');
413
413
  if (!found) found = getAttribute(ele, 'i18n-ns');
414
414
  if (!found) found = getAttribute(ele, 'data-i18n-ns');
415
- if (!found && ele.parentElement) find(ele.parentElement);
415
+ if (!found && ele.parentElement) _find(ele.parentElement);
416
416
  };
417
- find(el);
417
+ _find(el);
418
418
  return found;
419
419
  }
420
420
  function getQsParameterByName(name, url) {
@@ -853,7 +853,7 @@
853
853
  var popup = document.createElement('div');
854
854
  popup.setAttribute('id', popupId);
855
855
  popup.classList.add('i18next-editor-popup');
856
- popup.style = "\n background-color: transparent;\n border: 1px solid rgba(200, 200, 200, 0.9);\n box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);\n border-radius: 3px;\n --i18next-editor-popup-height: 200px;\n height: var(--i18next-editor-popup-height);\n min-height: 150px;\n min-width: 300px;\n --i18next-editor-popup-width: 400px;\n width: var(--i18next-editor-popup-width);\n max-height: 800px;\n max-width: 1000px;\n\n position: fixed;\n --i18next-editor-popup-position-top: calc(100vh - var(--i18next-editor-popup-height) - 10px);\n top: calc(100vh - var(--i18next-editor-popup-height) - 10px);\n --i18next-editor-popup-position-left: calc(100vw - var(--i18next-editor-popup-width) - 10px);\n left: calc(100vw - var(--i18next-editor-popup-width) - 10px);\n\n overflow: visible;\n z-index: 99999;\n ";
856
+ popup.style = "\n background-color: transparent;\n border: 1px solid rgba(200, 200, 200, 0.9);\n box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);\n border-radius: 3px;\n --i18next-editor-popup-height: 200px;\n height: var(--i18next-editor-popup-height);\n min-height: 150px;\n min-width: 300px;\n --i18next-editor-popup-width: 400px;\n width: var(--i18next-editor-popup-width);\n max-height: 800px;\n max-width: 1000px;\n\n position: fixed;\n --i18next-editor-popup-position-top: calc(100vh - var(--i18next-editor-popup-height) - 10px);\n top: calc(100vh - var(--i18next-editor-popup-height) - 10px);\n --i18next-editor-popup-position-left: calc(100vw - var(--i18next-editor-popup-width) - 10px);\n left: calc(100vw - var(--i18next-editor-popup-width) - 10px);\n\n overflow: visible;\n z-index: 100000;\n ";
857
857
  popup.setAttribute('data-i18next-editor-element', 'true');
858
858
  var header = document.createElement('div');
859
859
  header.classList.add('i18next-editor-popup-header');
@@ -1053,7 +1053,7 @@
1053
1053
  var rect = ele.getBoundingClientRect();
1054
1054
  var box = document.createElement('div');
1055
1055
  box.classList.add('i18next-editor-highlight');
1056
- box.style = "position: absolute; z-index: 99999; pointer-events: none; top: ".concat(rect.top - 2 + window.scrollY, "px; left: ").concat(rect.left - 2 + window.scrollX, "px; height: ").concat(rect.height + 4, "px; width: ").concat(rect.width + 4, "px; border: 1px solid ").concat(borderColor, "; border-radius: 2px; ").concat(shadowColor ? "box-shadow: 0 0 20px 0 ".concat(shadowColor, ";") : '');
1056
+ box.style = "position: absolute; z-index: 99999; pointer-events: none; top: ".concat(rect.top - 2 + window.scrollY, "px; left: ").concat(rect.left - 2 + window.scrollX, "px; height: ").concat(rect.height + 4, "px; width: ").concat(rect.width + 4, "px; border: ").concat(borderColor === 'none' ? 'none' : "1px solid ".concat(borderColor), "; border-radius: 15px; ").concat(shadowColor ? "box-shadow: inset 1px 1px 5px rgba(255, 255, 255, 0.1), inset -1px -1px 5px rgba(61, 67, 69, 0.3), 0 0 20px 0 ".concat(shadowColor, ";") : '');
1057
1057
  box.setAttribute('data-i18next-editor-element', 'true');
1058
1058
  return box;
1059
1059
  }
@@ -1101,8 +1101,9 @@
1101
1101
  function getAxisLength(axis) {
1102
1102
  return axis === 'y' ? 'height' : 'width';
1103
1103
  }
1104
+ const yAxisSides = /*#__PURE__*/new Set(['top', 'bottom']);
1104
1105
  function getSideAxis(placement) {
1105
- return ['top', 'bottom'].includes(getSide(placement)) ? 'y' : 'x';
1106
+ return yAxisSides.has(getSide(placement)) ? 'y' : 'x';
1106
1107
  }
1107
1108
  function getAlignmentAxis(placement) {
1108
1109
  return getOppositeAxis(getSideAxis(placement));
@@ -1127,19 +1128,19 @@
1127
1128
  function getOppositeAlignmentPlacement(placement) {
1128
1129
  return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);
1129
1130
  }
1131
+ const lrPlacement = ['left', 'right'];
1132
+ const rlPlacement = ['right', 'left'];
1133
+ const tbPlacement = ['top', 'bottom'];
1134
+ const btPlacement = ['bottom', 'top'];
1130
1135
  function getSideList(side, isStart, rtl) {
1131
- const lr = ['left', 'right'];
1132
- const rl = ['right', 'left'];
1133
- const tb = ['top', 'bottom'];
1134
- const bt = ['bottom', 'top'];
1135
1136
  switch (side) {
1136
1137
  case 'top':
1137
1138
  case 'bottom':
1138
- if (rtl) return isStart ? rl : lr;
1139
- return isStart ? lr : rl;
1139
+ if (rtl) return isStart ? rlPlacement : lrPlacement;
1140
+ return isStart ? lrPlacement : rlPlacement;
1140
1141
  case 'left':
1141
1142
  case 'right':
1142
- return isStart ? tb : bt;
1143
+ return isStart ? tbPlacement : btPlacement;
1143
1144
  default:
1144
1145
  return [];
1145
1146
  }
@@ -1662,16 +1663,22 @@
1662
1663
  const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
1663
1664
  const nextPlacement = placements[nextIndex];
1664
1665
  if (nextPlacement) {
1665
- // Try next placement and re-run the lifecycle.
1666
- return {
1667
- data: {
1668
- index: nextIndex,
1669
- overflows: overflowsData
1670
- },
1671
- reset: {
1672
- placement: nextPlacement
1673
- }
1674
- };
1666
+ const ignoreCrossAxisOverflow = checkCrossAxis === 'alignment' ? initialSideAxis !== getSideAxis(nextPlacement) : false;
1667
+ if (!ignoreCrossAxisOverflow ||
1668
+ // We leave the current main axis only if every placement on that axis
1669
+ // overflows the main axis.
1670
+ overflowsData.every(d => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) {
1671
+ // Try next placement and re-run the lifecycle.
1672
+ return {
1673
+ data: {
1674
+ index: nextIndex,
1675
+ overflows: overflowsData
1676
+ },
1677
+ reset: {
1678
+ placement: nextPlacement
1679
+ }
1680
+ };
1681
+ }
1675
1682
  }
1676
1683
 
1677
1684
  // First, find the candidates that fit on the mainAxis side of overflow,
@@ -1917,6 +1924,8 @@
1917
1924
  };
1918
1925
  };
1919
1926
 
1927
+ const originSides = /*#__PURE__*/new Set(['left', 'top']);
1928
+
1920
1929
  // For type backwards-compatibility, the `OffsetOptions` type was also
1921
1930
  // Derivable.
1922
1931
 
@@ -1930,7 +1939,7 @@
1930
1939
  const side = getSide(placement);
1931
1940
  const alignment = getAlignment(placement);
1932
1941
  const isVertical = getSideAxis(placement) === 'y';
1933
- const mainAxisMulti = ['left', 'top'].includes(side) ? -1 : 1;
1942
+ const mainAxisMulti = originSides.has(side) ? -1 : 1;
1934
1943
  const crossAxisMulti = rtl && isVertical ? -1 : 1;
1935
1944
  const rawValue = evaluate(options, state);
1936
1945
 
@@ -2130,7 +2139,7 @@
2130
2139
  if (checkCrossAxis) {
2131
2140
  var _middlewareData$offse, _middlewareData$offse2;
2132
2141
  const len = mainAxis === 'y' ? 'width' : 'height';
2133
- const isOriginSide = ['top', 'left'].includes(getSide(placement));
2142
+ const isOriginSide = originSides.has(getSide(placement));
2134
2143
  const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);
2135
2144
  const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);
2136
2145
  if (crossAxisCoord < limitMin) {
@@ -2275,34 +2284,40 @@
2275
2284
  }
2276
2285
  return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
2277
2286
  }
2287
+ const invalidOverflowDisplayValues = /*#__PURE__*/new Set(['inline', 'contents']);
2278
2288
  function isOverflowElement(element) {
2279
2289
  const {
2280
2290
  overflow,
2281
2291
  overflowX,
2282
2292
  overflowY,
2283
2293
  display
2284
- } = getComputedStyle(element);
2285
- return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !['inline', 'contents'].includes(display);
2294
+ } = getComputedStyle$1(element);
2295
+ return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);
2286
2296
  }
2297
+ const tableElements = /*#__PURE__*/new Set(['table', 'td', 'th']);
2287
2298
  function isTableElement(element) {
2288
- return ['table', 'td', 'th'].includes(getNodeName(element));
2299
+ return tableElements.has(getNodeName(element));
2289
2300
  }
2301
+ const topLayerSelectors = [':popover-open', ':modal'];
2290
2302
  function isTopLayer(element) {
2291
- return [':popover-open', ':modal'].some(selector => {
2303
+ return topLayerSelectors.some(selector => {
2292
2304
  try {
2293
2305
  return element.matches(selector);
2294
- } catch (e) {
2306
+ } catch (_e) {
2295
2307
  return false;
2296
2308
  }
2297
2309
  });
2298
2310
  }
2311
+ const transformProperties = ['transform', 'translate', 'scale', 'rotate', 'perspective'];
2312
+ const willChangeValues = ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'];
2313
+ const containValues = ['paint', 'layout', 'strict', 'content'];
2299
2314
  function isContainingBlock(elementOrCss) {
2300
2315
  const webkit = isWebKit();
2301
- const css = isElement(elementOrCss) ? getComputedStyle(elementOrCss) : elementOrCss;
2316
+ const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
2302
2317
 
2303
2318
  // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
2304
2319
  // https://drafts.csswg.org/css-transforms-2/#individual-transforms
2305
- return ['transform', 'translate', 'scale', 'rotate', 'perspective'].some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'].some(value => (css.willChange || '').includes(value)) || ['paint', 'layout', 'strict', 'content'].some(value => (css.contain || '').includes(value));
2320
+ return transformProperties.some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || willChangeValues.some(value => (css.willChange || '').includes(value)) || containValues.some(value => (css.contain || '').includes(value));
2306
2321
  }
2307
2322
  function getContainingBlock(element) {
2308
2323
  let currentNode = getParentNode(element);
@@ -2320,10 +2335,11 @@
2320
2335
  if (typeof CSS === 'undefined' || !CSS.supports) return false;
2321
2336
  return CSS.supports('-webkit-backdrop-filter', 'none');
2322
2337
  }
2338
+ const lastTraversableNodeNames = /*#__PURE__*/new Set(['html', 'body', '#document']);
2323
2339
  function isLastTraversableNode(node) {
2324
- return ['html', 'body', '#document'].includes(getNodeName(node));
2340
+ return lastTraversableNodeNames.has(getNodeName(node));
2325
2341
  }
2326
- function getComputedStyle(element) {
2342
+ function getComputedStyle$1(element) {
2327
2343
  return getWindow(element).getComputedStyle(element);
2328
2344
  }
2329
2345
  function getNodeScroll(element) {
@@ -2385,7 +2401,7 @@
2385
2401
  }
2386
2402
 
2387
2403
  function getCssDimensions(element) {
2388
- const css = getComputedStyle(element);
2404
+ const css = getComputedStyle$1(element);
2389
2405
  // In testing environments, the `width` and `height` properties are empty
2390
2406
  // strings for SVG elements, returning NaN. Fallback to `0` in this case.
2391
2407
  let width = parseFloat(css.width) || 0;
@@ -2490,7 +2506,7 @@
2490
2506
  while (currentIFrame && offsetParent && offsetWin !== currentWin) {
2491
2507
  const iframeScale = getScale(currentIFrame);
2492
2508
  const iframeRect = currentIFrame.getBoundingClientRect();
2493
- const css = getComputedStyle(currentIFrame);
2509
+ const css = getComputedStyle$1(currentIFrame);
2494
2510
  const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
2495
2511
  const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
2496
2512
  x *= iframeScale.x;
@@ -2521,14 +2537,9 @@
2521
2537
  return rect.left + leftScroll;
2522
2538
  }
2523
2539
 
2524
- function getHTMLOffset(documentElement, scroll, ignoreScrollbarX) {
2525
- if (ignoreScrollbarX === void 0) {
2526
- ignoreScrollbarX = false;
2527
- }
2540
+ function getHTMLOffset(documentElement, scroll) {
2528
2541
  const htmlRect = documentElement.getBoundingClientRect();
2529
- const x = htmlRect.left + scroll.scrollLeft - (ignoreScrollbarX ? 0 :
2530
- // RTL <body> scrollbar.
2531
- getWindowScrollBarX(documentElement, htmlRect));
2542
+ const x = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);
2532
2543
  const y = htmlRect.top + scroll.scrollTop;
2533
2544
  return {
2534
2545
  x,
@@ -2567,7 +2578,7 @@
2567
2578
  offsets.y = offsetRect.y + offsetParent.clientTop;
2568
2579
  }
2569
2580
  }
2570
- const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll, true) : createCoords(0);
2581
+ const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
2571
2582
  return {
2572
2583
  width: rect.width * scale.x,
2573
2584
  height: rect.height * scale.y,
@@ -2590,7 +2601,7 @@
2590
2601
  const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
2591
2602
  let x = -scroll.scrollLeft + getWindowScrollBarX(element);
2592
2603
  const y = -scroll.scrollTop;
2593
- if (getComputedStyle(body).direction === 'rtl') {
2604
+ if (getComputedStyle$1(body).direction === 'rtl') {
2594
2605
  x += max(html.clientWidth, body.clientWidth) - width;
2595
2606
  }
2596
2607
  return {
@@ -2601,6 +2612,10 @@
2601
2612
  };
2602
2613
  }
2603
2614
 
2615
+ // Safety check: ensure the scrollbar space is reasonable in case this
2616
+ // calculation is affected by unusual styles.
2617
+ // Most scrollbars leave 15-18px of space.
2618
+ const SCROLLBAR_MAX = 25;
2604
2619
  function getViewportRect(element, strategy) {
2605
2620
  const win = getWindow(element);
2606
2621
  const html = getDocumentElement(element);
@@ -2618,6 +2633,24 @@
2618
2633
  y = visualViewport.offsetTop;
2619
2634
  }
2620
2635
  }
2636
+ const windowScrollbarX = getWindowScrollBarX(html);
2637
+ // <html> `overflow: hidden` + `scrollbar-gutter: stable` reduces the
2638
+ // visual width of the <html> but this is not considered in the size
2639
+ // of `html.clientWidth`.
2640
+ if (windowScrollbarX <= 0) {
2641
+ const doc = html.ownerDocument;
2642
+ const body = doc.body;
2643
+ const bodyStyles = getComputedStyle(body);
2644
+ const bodyMarginInline = doc.compatMode === 'CSS1Compat' ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;
2645
+ const clippingStableScrollbarWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);
2646
+ if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {
2647
+ width -= clippingStableScrollbarWidth;
2648
+ }
2649
+ } else if (windowScrollbarX <= SCROLLBAR_MAX) {
2650
+ // If the <body> scrollbar is on the left, the width needs to be extended
2651
+ // by the scrollbar amount so there isn't extra space on the right.
2652
+ width += windowScrollbarX;
2653
+ }
2621
2654
  return {
2622
2655
  width,
2623
2656
  height,
@@ -2626,6 +2659,7 @@
2626
2659
  };
2627
2660
  }
2628
2661
 
2662
+ const absoluteOrFixed = /*#__PURE__*/new Set(['absolute', 'fixed']);
2629
2663
  // Returns the inner client rect, subtracting scrollbars if present.
2630
2664
  function getInnerBoundingClientRect(element, strategy) {
2631
2665
  const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');
@@ -2667,7 +2701,7 @@
2667
2701
  if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {
2668
2702
  return false;
2669
2703
  }
2670
- return getComputedStyle(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);
2704
+ return getComputedStyle$1(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);
2671
2705
  }
2672
2706
 
2673
2707
  // A "clipping ancestor" is an `overflow` element with the characteristic of
@@ -2680,17 +2714,17 @@
2680
2714
  }
2681
2715
  let result = getOverflowAncestors(element, [], false).filter(el => isElement(el) && getNodeName(el) !== 'body');
2682
2716
  let currentContainingBlockComputedStyle = null;
2683
- const elementIsFixed = getComputedStyle(element).position === 'fixed';
2717
+ const elementIsFixed = getComputedStyle$1(element).position === 'fixed';
2684
2718
  let currentNode = elementIsFixed ? getParentNode(element) : element;
2685
2719
 
2686
2720
  // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
2687
2721
  while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {
2688
- const computedStyle = getComputedStyle(currentNode);
2722
+ const computedStyle = getComputedStyle$1(currentNode);
2689
2723
  const currentNodeIsContaining = isContainingBlock(currentNode);
2690
2724
  if (!currentNodeIsContaining && computedStyle.position === 'fixed') {
2691
2725
  currentContainingBlockComputedStyle = null;
2692
2726
  }
2693
- const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && ['absolute', 'fixed'].includes(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
2727
+ const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && absoluteOrFixed.has(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
2694
2728
  if (shouldDropCurrentNode) {
2695
2729
  // Drop non-containing blocks.
2696
2730
  result = result.filter(ancestor => ancestor !== currentNode);
@@ -2753,6 +2787,12 @@
2753
2787
  scrollTop: 0
2754
2788
  };
2755
2789
  const offsets = createCoords(0);
2790
+
2791
+ // If the <body> scrollbar appears on the left (e.g. RTL systems). Use
2792
+ // Firefox with layout.scrollbar.side = 3 in about:config to test this.
2793
+ function setLeftRTLScrollbarOffset() {
2794
+ offsets.x = getWindowScrollBarX(documentElement);
2795
+ }
2756
2796
  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
2757
2797
  if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
2758
2798
  scroll = getNodeScroll(offsetParent);
@@ -2762,11 +2802,12 @@
2762
2802
  offsets.x = offsetRect.x + offsetParent.clientLeft;
2763
2803
  offsets.y = offsetRect.y + offsetParent.clientTop;
2764
2804
  } else if (documentElement) {
2765
- // If the <body> scrollbar appears on the left (e.g. RTL systems). Use
2766
- // Firefox with layout.scrollbar.side = 3 in about:config to test this.
2767
- offsets.x = getWindowScrollBarX(documentElement);
2805
+ setLeftRTLScrollbarOffset();
2768
2806
  }
2769
2807
  }
2808
+ if (isFixed && !isOffsetParentAnElement && documentElement) {
2809
+ setLeftRTLScrollbarOffset();
2810
+ }
2770
2811
  const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
2771
2812
  const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
2772
2813
  const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
@@ -2779,11 +2820,11 @@
2779
2820
  }
2780
2821
 
2781
2822
  function isStaticPositioned(element) {
2782
- return getComputedStyle(element).position === 'static';
2823
+ return getComputedStyle$1(element).position === 'static';
2783
2824
  }
2784
2825
 
2785
2826
  function getTrueOffsetParent(element, polyfill) {
2786
- if (!isHTMLElement(element) || getComputedStyle(element).position === 'fixed') {
2827
+ if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {
2787
2828
  return null;
2788
2829
  }
2789
2830
  if (polyfill) {
@@ -2844,7 +2885,7 @@
2844
2885
  };
2845
2886
 
2846
2887
  function isRTL(element) {
2847
- return getComputedStyle(element).direction === 'rtl';
2888
+ return getComputedStyle$1(element).direction === 'rtl';
2848
2889
  }
2849
2890
 
2850
2891
  const platform = {
@@ -2953,7 +2994,7 @@
2953
2994
  function highlight(item, node, keys) {
2954
2995
  var rectEle = getOptimizedBoundingRectEle(node);
2955
2996
  if (!item.highlightBox) {
2956
- var box = HighlightBox(rectEle, colors.highlight);
2997
+ var box = HighlightBox(rectEle, 'none', 'rgba(0,0,0,0.1)');
2957
2998
  document.body.appendChild(box);
2958
2999
  item.highlightBox = box;
2959
3000
  }
@@ -3020,7 +3061,7 @@
3020
3061
  var id = item.id;
3021
3062
  var rectEle = getOptimizedBoundingRectEle(node);
3022
3063
  if (!item.highlightBox) {
3023
- var box = HighlightBox(rectEle, colors.highlight, colors.gray);
3064
+ var box = HighlightBox(rectEle, 'none', colors.gray);
3024
3065
  document.body.appendChild(box);
3025
3066
  item.highlightBox = box;
3026
3067
  }
@@ -3412,7 +3453,7 @@
3412
3453
  var popups = document.getElementsByClassName('i18next-editor-popup');
3413
3454
  var elmnt = null;
3414
3455
  var overlay = null;
3415
- var currentZIndex = 100;
3456
+ var currentZIndex = 100000;
3416
3457
  for (var i = 0; i < popups.length; i++) {
3417
3458
  var popup = popups[i];
3418
3459
  var header = getHeader(popup);