@dotdev/next-components
Advanced tools
Comparing version 0.4.8 to 0.4.9
@@ -64,3 +64,2 @@ "use strict"; | ||
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: "/apps/toolkit/wishlist/:id", render: function (props) { return (React.createElement(_this.props.templates.wishlist, __assign({}, props, _this.props))); } }), | ||
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))); } }), | ||
@@ -67,0 +66,0 @@ React.createElement(react_router_dom_1.Route, { render: function (props) { return (React.createElement(_this.props.templates.notFound, __assign({}, props, _this.props))); } })))); |
@@ -1,2 +0,1 @@ | ||
import "whatwg-fetch"; | ||
export declare class Cart { | ||
@@ -6,3 +5,3 @@ private context; | ||
constructor(); | ||
init: (context: any, data: any) => void; | ||
init: (context: any) => void; | ||
triggerPaymentButtons: () => void; | ||
@@ -9,0 +8,0 @@ getCartJSON: () => void; |
@@ -50,3 +50,2 @@ "use strict"; | ||
var cart = require("@shopify/theme-cart"); | ||
require("whatwg-fetch"); | ||
var Cart = /** @class */ (function () { | ||
@@ -57,3 +56,3 @@ function Cart() { | ||
this.cart = null; | ||
this.init = function (context, data) { | ||
this.init = function (context) { | ||
_this.context = context; | ||
@@ -60,0 +59,0 @@ }; |
export * from "./cart"; | ||
export * from "./helpers"; | ||
export * from "./notifications"; | ||
export * from "./wishlist"; |
@@ -7,5 +7,3 @@ "use strict"; | ||
__export(require("./cart")); | ||
__export(require("./helpers")); | ||
__export(require("./notifications")); | ||
__export(require("./wishlist")); | ||
//# sourceMappingURL=index.js.map |
@@ -5,3 +5,3 @@ export declare class Notifications { | ||
constructor(); | ||
init: (context: any, data: any) => void; | ||
init: (context: any) => void; | ||
set: (messages: Notifications.Messages) => Notifications.Messages; | ||
@@ -30,23 +30,3 @@ get: (message: string) => any; | ||
PRODUCT_RECOMMENDATIONS_FAILED: string; | ||
WISHLIST_REQUEST_SUCCESS: string; | ||
WISHLIST_REQUEST_FAILED: string; | ||
WISHLIST_ITEM_ADDED_SUCCESS: string; | ||
WISHLIST_ITEM_ADDED_FAILED: string; | ||
WISHLIST_ITEM_REMOVED_SUCCESS: string; | ||
WISHLIST_ITEM_REMOVED_FAILED: string; | ||
WISHLIST_ITEM_UPDATED_SUCCESS: string; | ||
WISHLIST_ITEM_UPDATED_FAILED: string; | ||
WISHLIST_SHARED_SUCCESS: string; | ||
WISHLIST_SHARED_FAILED: string; | ||
WISHLIST_DUPLICATE_SUCCESS: string; | ||
WISHLIST_DUPLICATE_FAILED: string; | ||
WISHLIST_MIGRATE_SUCCESS: string; | ||
WISHLIST_MIGRATE_FAILED: string; | ||
HELPERS_PRODUCTS_SUCCESS: string; | ||
HELPERS_PRODUCTS_FAILED: string; | ||
HELPERS_GIFTCARD_SUCCESS: string; | ||
HELPERS_GIFTCARD_FAILED: string; | ||
HELPERS_CUSTOMER_SUCCESS: string; | ||
HELPERS_CUSTOMER_FAILED: string; | ||
} | ||
} |
@@ -8,3 +8,3 @@ "use strict"; | ||
this.messages = null; | ||
this.init = function (context, data) { | ||
this.init = function (context) { | ||
_this.context = context; | ||
@@ -11,0 +11,0 @@ }; |
@@ -5,3 +5,2 @@ import * as React from "react"; | ||
update: (newState: any) => void; | ||
getContext: () => any; | ||
render(): JSX.Element; | ||
@@ -8,0 +7,0 @@ } |
@@ -38,5 +38,2 @@ "use strict"; | ||
}; | ||
_this.getContext = function () { | ||
return _this.state; | ||
}; | ||
_this.state = { | ||
@@ -48,2 +45,5 @@ state: __assign({}, _this.props.value), | ||
} | ||
// public update = (state: any): void => { | ||
// this.setState({...state}); | ||
// } | ||
ThemeProvider.prototype.render = function () { | ||
@@ -50,0 +50,0 @@ return (React.createElement(context_1.ThemeContext.Provider, { value: this.state }, this.props.children)); |
import * as React from "react"; | ||
import { RouterProps } from "react-router"; | ||
import "url-search-params-polyfill"; | ||
import { ThemeContext } from "./context"; | ||
import { Shop, Template, LinkList, Filters, Form, Breadcrumbs, Search } from "./types"; | ||
import { Cart, Helpers, Notifications, Wishlist } from "./helpers"; | ||
import { Cart, Notifications } from "./helpers"; | ||
import * as Components from "./components"; | ||
@@ -15,5 +14,3 @@ import * as Utils from "./utils"; | ||
static Cart: Cart; | ||
static Wishlist: Wishlist; | ||
static Notifications: Notifications; | ||
static Helpers: Helpers; | ||
constructor(options: ShopifyNext.Options); | ||
@@ -46,3 +43,2 @@ element(data?: any): JSX.Element; | ||
giftcard: typeof React.Component; | ||
wishlist: typeof React.Component; | ||
home: typeof React.Component; | ||
@@ -85,3 +81,2 @@ page: typeof React.Component; | ||
settings: SettingsData; | ||
wishlist: any; | ||
shop: Shop; | ||
@@ -88,0 +83,0 @@ template: Template; |
@@ -14,3 +14,2 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("url-search-params-polyfill"); | ||
var context_1 = require("./context"); | ||
@@ -83,5 +82,3 @@ var bootstrap_1 = require("./bootstrap"); | ||
ShopifyNext.Cart = new helpers_1.Cart(); | ||
ShopifyNext.Wishlist = new helpers_1.Wishlist(); | ||
ShopifyNext.Notifications = new helpers_1.Notifications(); | ||
ShopifyNext.Helpers = new helpers_1.Helpers(); | ||
return ShopifyNext; | ||
@@ -88,0 +85,0 @@ }()); |
{ | ||
"name": "@dotdev/next-components", | ||
"version": "0.4.8", | ||
"version": "0.4.9", | ||
"license": "UNLICENSED", | ||
@@ -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
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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4
82657
94
1234