Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@dotdev/next-components

Package Overview
Dependencies
Maintainers
13
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dotdev/next-components - npm Package Compare versions

Comparing version 1.0.5 to 1.0.6

2

dist/bootstrap.js

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

React.createElement(react_router_dom_1.Route, { exact: true, path: "/account/logout", render: function (props) { return (React.createElement(_this.props.templates.account.logout, __assign({}, props, _this.props))); } }),
React.createElement(react_router_dom_1.Route, { exact: true, path: "/giftcard/:number", render: function (props) { return (React.createElement(_this.props.templates.giftcard, __assign({}, props, _this.props))); } }),
React.createElement(react_router_dom_1.Route, { exact: true, path: "/gift_cards/:id/:token", render: function (props) { return (React.createElement(_this.props.templates.giftcard, __assign({}, props, _this.props))); } }),
React.createElement(react_router_dom_1.Route, { exact: true, path: "/apps/toolkit/wishlist/:id", render: function (props) { return (React.createElement(_this.props.templates.wishlist, __assign({}, props, _this.props))); } }),

@@ -66,0 +66,0 @@ React.createElement(react_router_dom_1.Route, { exact: true, path: "/password", render: function (props) { return (React.createElement(_this.props.templates.password, __assign({}, props, _this.props))); } }),

@@ -7,2 +7,3 @@ import * as React from "react";

private transform;
private legacyTransform;
render(): JSX.Element;

@@ -9,0 +10,0 @@ }

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

_this.transform = function (data) {
if (0 < data.length && !data[0]._name) {
return _this.legacyTransform(data);
}
var sections = [];
data.map(function (item, index) {
var blockKeys = Object.keys(item).filter(function (itemKey) {
return itemKey.startsWith("blocks");
});
var blocks = blockKeys.reduce(function (allBlocks, blockKey) {
var _a;
return (__assign({}, allBlocks, (_a = {}, _a[blockKey] = (item[blockKey] || []).map(function (block, i) { return ({
id: i,
type: "default",
settings: block
}); }), _a)));
}, {});
var fields = item;
delete fields.blocks;
sections.push(__assign({ id: index + "_" + item._name, type: "dynamic", name: item._name, settings: fields }, blocks));
});
return sections;
};
_this.legacyTransform = function (data) {
var sections = [];
data.map(function (item) {

@@ -36,0 +59,0 @@ Object.keys(item).forEach(function (key) {

@@ -17,2 +17,3 @@ export declare class Notifications {

CART_ITEM_REMOVED_FAILED: string;
CART_NOTE_UPDATE_SUCCESS: string;
CART_QTY_UPDATE_SUCCESS: string;

@@ -19,0 +20,0 @@ CART_QTY_UPDATE_FAILED: string;

@@ -123,4 +123,6 @@ "use strict";

var items = JSON.parse(local) ? JSON.parse(local).items : [];
return items.length ? items.filter(function (item) { return parseInt(item.variantId) == variantId; })
.length : false;
return items.length
? items.filter(function (item) { return parseInt(item.variantId) == variantId; })
.length
: false;
};

@@ -127,0 +129,0 @@ this.addItem = function (productId, variantId) {

{
"name": "@dotdev/next-components",
"version": "1.0.5",
"version": "1.0.6",
"license": "SEE LICENSE IN LICENCE.md",

@@ -5,0 +5,0 @@ "description": "Common components for Next projects",

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