UNPKG

@taiga-ui/cdk

Version:

Base library for creating Angular components and applications using Taiga UI principles regarding of actual visual appearance

14 lines (13 loc) 514 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.migrateLessSCSSConstants = void 0; const MAPPING = { space: '0.25rem', }; function migrateLessSCSSConstants(fileContent) { if (!fileContent.includes('@taiga-ui/core/styles/taiga-ui-local')) { return fileContent; } return fileContent.replaceAll(new RegExp(`[$|@](${Object.keys(MAPPING).join('|')})`, 'g'), (_, variable) => MAPPING[variable]); } exports.migrateLessSCSSConstants = migrateLessSCSSConstants;