@akinon/next 1.4.0 → 1.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # @akinon/next
2
2
 
3
+ ## 1.5.0
4
+
5
+ ### Patch Changes
6
+
7
+ - Support GPay plugin
8
+ - Extend Next Metadata type
9
+
3
10
  ## 1.4.0
4
11
 
5
12
  ### Minor Changes
@@ -8,7 +8,8 @@ enum Plugin {
8
8
  ClickCollect = 'pz-click-collect',
9
9
  OneClickCheckout = 'pz-one-click-checkout',
10
10
  PayOnDelivery = 'pz-pay-on-delivery',
11
- CheckoutGiftPack = 'pz-checkout-gift-pack'
11
+ CheckoutGiftPack = 'pz-checkout-gift-pack',
12
+ GPay = 'pz-gpay'
12
13
  }
13
14
 
14
15
  export enum Component {
@@ -16,7 +17,8 @@ export enum Component {
16
17
  ClickCollect = 'ClickCollect',
17
18
  OneClickCheckoutButtons = 'OneClickCheckoutButtons',
18
19
  PayOnDelivery = 'PayOnDelivery',
19
- CheckoutGiftPack = 'CheckoutGiftPack'
20
+ CheckoutGiftPack = 'CheckoutGiftPack',
21
+ GPay = 'GPayOption'
20
22
  }
21
23
 
22
24
  const PluginComponents = new Map([
@@ -24,7 +26,8 @@ const PluginComponents = new Map([
24
26
  [Plugin.ClickCollect, [Component.ClickCollect]],
25
27
  [Plugin.OneClickCheckout, [Component.OneClickCheckoutButtons]],
26
28
  [Plugin.PayOnDelivery, [Component.PayOnDelivery]],
27
- [Plugin.CheckoutGiftPack, [Component.CheckoutGiftPack]]
29
+ [Plugin.CheckoutGiftPack, [Component.CheckoutGiftPack]],
30
+ [Plugin.GPay, [Component.GPay]]
28
31
  ]);
29
32
 
30
33
  const getPlugin = (component: Component) => {
@@ -65,6 +68,8 @@ export default function PluginModule({
65
68
  promise = import(`${'pz-pay-on-delivery'}`);
66
69
  } else if (plugin === Plugin.CheckoutGiftPack) {
67
70
  promise = import(`${'pz-checkout-gift-pack'}`);
71
+ } else if (plugin === Plugin.GPay) {
72
+ promise = import(`${'pz-gpay'}`);
68
73
  }
69
74
  } catch (error) {
70
75
  logger.error(error);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@akinon/next",
3
3
  "description": "Core package for Project Zero Next",
4
- "version": "1.4.0",
4
+ "version": "1.5.0",
5
5
  "private": false,
6
6
  "license": "MIT",
7
7
  "bin": {
package/types/index.ts CHANGED
@@ -9,6 +9,7 @@ declare global {
9
9
 
10
10
  export * from './commerce';
11
11
  export * from './gtm';
12
+ export * from './metadata';
12
13
 
13
14
  export interface Locale {
14
15
  label: string;
@@ -0,0 +1,7 @@
1
+ import { Metadata as NextMetaData } from 'next';
2
+
3
+ export interface Metadata extends NextMetaData {
4
+ alternates?: {
5
+ languages: Record<string, string>;
6
+ };
7
+ }