Socket
Socket
Sign inDemoInstall

wix-style-processor

Package Overview
Dependencies
Maintainers
8
Versions
188
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

wix-style-processor - npm Package Compare versions

Comparing version 3.1.11 to 3.1.12

2

dist/es/src/defaultPlugins.js

@@ -66,3 +66,3 @@ var __assign = (this && this.__assign) || function () {

var _a = parseJson(font), theme = _a.theme, overrides = __rest(_a, ["theme"]);
fontValue = __assign({ style: '', variant: '', weight: '', stretch: '', size: '', lineHeight: '', family: [] }, tpaParams.fonts[theme], overrides);
fontValue = __assign(__assign({ style: '', variant: '', weight: '', stretch: '', size: '', lineHeight: '', family: [] }, tpaParams.fonts[theme]), overrides);
}

@@ -69,0 +69,0 @@ else if (tpaParams.fonts[font]) {

@@ -18,3 +18,3 @@ function isIE() {

isCssVarsSupported: function () {
return !!(window && window.CSS && window.CSS.supports && window.CSS.supports('--fake-var', 0));
return !!(window && window.CSS && window.CSS.supports && window.CSS.supports('--fake-var', '0'));
},

@@ -21,0 +21,0 @@ updateCssVars: function (varMap) {

@@ -35,3 +35,3 @@ var __assign = (this && this.__assign) || function () {

defaultOptions.shouldApplyCSSFunctions = !wixService.shouldRunAsStandalone();
options = __assign({}, defaultOptions, options);
options = __assign(__assign({}, defaultOptions), options);
this.styleUpdater = StyleUpdaterFactory(wixService, domService, options);

@@ -38,0 +38,0 @@ if (wixService.isEditorMode() || wixService.isPreviewMode()) {

@@ -0,1 +1,8 @@

var __spreadArrays = (this && this.__spreadArrays) || function () {
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
for (var r = Array(s), k = 0, i = 0; i < il; i++)
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
r[k] = a[j];
return r;
};
import { parenthesisAreBalanced } from './utils';

@@ -60,5 +67,5 @@ var paramsRegex = /,(?![^(]*(?:\)|}))/g;

}
return function (tpaParams) { return fnToWrap.apply(void 0, args.map(function (fn) { return fn(tpaParams); }).concat([tpaParams])); };
return function (tpaParams) { return fnToWrap.apply(void 0, __spreadArrays(args.map(function (fn) { return fn(tpaParams); }), [tpaParams])); };
};
}
//# sourceMappingURL=plugins.js.map

@@ -31,3 +31,3 @@ var __assign = (this && this.__assign) || function () {

});
returnValue = __assign({}, returnValue, fixedColorStyles);
returnValue = __assign(__assign({}, returnValue), fixedColorStyles);
// Fix for a bug in a very specific template

@@ -34,0 +34,0 @@ returnValue.background = (fixedColorStyles.background || {}).value || (returnValue['color-1'] === '#FFFFFF') && (returnValue['color-2'] === '#F4EFE1') ? returnValue['color-2'] : returnValue['color-1'];

@@ -24,3 +24,3 @@ var __assign = (this && this.__assign) || function () {

var presetValue = preset.value.replace(/^font\s*:\s*/, '');
parsedSiteTextPresets[key] = __assign({}, parseCssFont(presetValue), { preset: key, editorKey: preset.editorKey }, (preset.displayName ? { displayName: preset.displayName } : {}));
parsedSiteTextPresets[key] = __assign(__assign(__assign({}, parseCssFont(presetValue)), { preset: key, editorKey: preset.editorKey }), (preset.displayName ? { displayName: preset.displayName } : {}));
});

@@ -35,5 +35,5 @@ var parsedFontStyles = {};

ret.STRONG = parseCssFont('12px HelveticaNeueW01-65Medi');
ret = __assign({}, ret, parsedFontStyles);
ret = __assign(__assign({}, ret), parsedFontStyles);
forEach(ret, function (font, key) {
ret[key] = __assign({}, font, { supports: { uppercase: true } });
ret[key] = __assign(__assign({}, font), { supports: { uppercase: true } });
if (['snellroundhandw', 'niconne'].some(function (fontName) { return font.family.indexOf(fontName) > -1; })) {

@@ -40,0 +40,0 @@ ret[key].supports.uppercase = false;

var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());

@@ -36,3 +37,2 @@ });

};
var _this = this;
import { $, $$, browser, ExpectedConditions } from 'protractor';

@@ -55,3 +55,3 @@ function waitForVisibilityOf(element) {

describe('Style Processor Scenario', function () {
beforeEach(function () { return __awaiter(_this, void 0, void 0, function () {
beforeEach(function () { return __awaiter(void 0, void 0, void 0, function () {
return __generator(this, function (_a) {

@@ -69,3 +69,3 @@ switch (_a.label) {

}); });
it('should not change the number of style tags', function () { return __awaiter(_this, void 0, void 0, function () {
it('should not change the number of style tags', function () { return __awaiter(void 0, void 0, void 0, function () {
var styleNum, _a, _b;

@@ -101,3 +101,3 @@ return __generator(this, function (_c) {

}); });
it('should update styles after change from sdk', function () { return __awaiter(_this, void 0, void 0, function () {
it('should update styles after change from sdk', function () { return __awaiter(void 0, void 0, void 0, function () {
var styleNum, _a, _b;

@@ -104,0 +104,0 @@ return __generator(this, function (_c) {

@@ -68,3 +68,3 @@ "use strict";

var _a = utils_1.parseJson(font), theme = _a.theme, overrides = __rest(_a, ["theme"]);
fontValue = __assign({ style: '', variant: '', weight: '', stretch: '', size: '', lineHeight: '', family: [] }, tpaParams.fonts[theme], overrides);
fontValue = __assign(__assign({ style: '', variant: '', weight: '', stretch: '', size: '', lineHeight: '', family: [] }, tpaParams.fonts[theme]), overrides);
}

@@ -71,0 +71,0 @@ else if (tpaParams.fonts[font]) {

@@ -20,3 +20,3 @@ "use strict";

isCssVarsSupported: function () {
return !!(window && window.CSS && window.CSS.supports && window.CSS.supports('--fake-var', 0));
return !!(window && window.CSS && window.CSS.supports && window.CSS.supports('--fake-var', '0'));
},

@@ -23,0 +23,0 @@ updateCssVars: function (varMap) {

@@ -37,3 +37,3 @@ "use strict";

defaultOptions.shouldApplyCSSFunctions = !wixService.shouldRunAsStandalone();
options = __assign({}, defaultOptions, options);
options = __assign(__assign({}, defaultOptions), options);
this.styleUpdater = styleUpdater_1.StyleUpdaterFactory(wixService, domService, options);

@@ -40,0 +40,0 @@ if (wixService.isEditorMode() || wixService.isPreviewMode()) {

"use strict";
var __spreadArrays = (this && this.__spreadArrays) || function () {
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
for (var r = Array(s), k = 0, i = 0; i < il; i++)
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
r[k] = a[j];
return r;
};
Object.defineProperty(exports, "__esModule", { value: true });

@@ -62,5 +69,5 @@ var utils_1 = require("./utils");

}
return function (tpaParams) { return fnToWrap.apply(void 0, args.map(function (fn) { return fn(tpaParams); }).concat([tpaParams])); };
return function (tpaParams) { return fnToWrap.apply(void 0, __spreadArrays(args.map(function (fn) { return fn(tpaParams); }), [tpaParams])); };
};
}
//# sourceMappingURL=plugins.js.map

@@ -33,3 +33,3 @@ "use strict";

});
returnValue = __assign({}, returnValue, fixedColorStyles);
returnValue = __assign(__assign({}, returnValue), fixedColorStyles);
// Fix for a bug in a very specific template

@@ -36,0 +36,0 @@ returnValue.background = (fixedColorStyles.background || {}).value || (returnValue['color-1'] === '#FFFFFF') && (returnValue['color-2'] === '#F4EFE1') ? returnValue['color-2'] : returnValue['color-1'];

@@ -26,3 +26,3 @@ "use strict";

var presetValue = preset.value.replace(/^font\s*:\s*/, '');
parsedSiteTextPresets[key] = __assign({}, parse_css_font_1.default(presetValue), { preset: key, editorKey: preset.editorKey }, (preset.displayName ? { displayName: preset.displayName } : {}));
parsedSiteTextPresets[key] = __assign(__assign(__assign({}, parse_css_font_1.default(presetValue)), { preset: key, editorKey: preset.editorKey }), (preset.displayName ? { displayName: preset.displayName } : {}));
});

@@ -37,5 +37,5 @@ var parsedFontStyles = {};

ret.STRONG = parse_css_font_1.default('12px HelveticaNeueW01-65Medi');
ret = __assign({}, ret, parsedFontStyles);
ret = __assign(__assign({}, ret), parsedFontStyles);
utils_1.forEach(ret, function (font, key) {
ret[key] = __assign({}, font, { supports: { uppercase: true } });
ret[key] = __assign(__assign({}, font), { supports: { uppercase: true } });
if (['snellroundhandw', 'niconne'].some(function (fontName) { return font.family.indexOf(fontName) > -1; })) {

@@ -42,0 +42,0 @@ ret[key].supports.uppercase = false;

@@ -5,3 +5,3 @@ {

"description": "An alternative Wix Styles TPA processor",
"version": "3.1.11",
"version": "3.1.12",
"author": {

@@ -8,0 +8,0 @@ "name": "Eran Shabi",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc