mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
fix: allow ignoring reduce-css-calc w/ webpack without error (#9510)
This commit is contained in:
committed by
Nathan Walker
parent
6d18915c22
commit
8c9407c48e
@@ -1,4 +1,3 @@
|
||||
import * as reduceCSSCalc from 'reduce-css-calc';
|
||||
|
||||
import { ViewBase } from '../view-base';
|
||||
|
||||
@@ -153,7 +152,7 @@ export function _evaluateCssCalcExpression(value: string) {
|
||||
|
||||
if (isCssCalcExpression(value)) {
|
||||
// WORKAROUND: reduce-css-calc can't handle the dip-unit.
|
||||
return reduceCSSCalc(value.replace(/([0-9]+(\.[0-9]+)?)dip\b/g, '$1'));
|
||||
return require('reduce-css-calc')(value.replace(/([0-9]+(\.[0-9]+)?)dip\b/g, '$1'));
|
||||
} else {
|
||||
return value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user