admin-shell-messaging
Advanced tools
Comparing version 0.1.3 to 0.1.4
@@ -1,2 +0,2 @@ | ||
import { InsertOnBreadcrumbParams } from "./types"; | ||
import { InsertOnBreadcrumbParams, Message } from "./types"; | ||
export declare enum ACTION_TYPES { | ||
@@ -9,24 +9,6 @@ START_LOADING = "START_LOADING", | ||
export declare const ACTIONS: { | ||
START_LOADING: () => { | ||
action: { | ||
type: ACTION_TYPES; | ||
}; | ||
}; | ||
STOP_LOADING: () => { | ||
action: { | ||
type: ACTION_TYPES; | ||
}; | ||
}; | ||
INSERT_BREADCRUMB_EXTRA_LEVEL: ({ newLevelName, previousLevelUrl, }: InsertOnBreadcrumbParams) => { | ||
action: { | ||
type: ACTION_TYPES; | ||
newLevelName: string; | ||
previousLevelUrl: string; | ||
}; | ||
}; | ||
CLEAR_BREADCRUMB_EXTRA_LEVELS: () => { | ||
action: { | ||
type: ACTION_TYPES; | ||
}; | ||
}; | ||
START_LOADING: () => Message; | ||
STOP_LOADING: () => Message; | ||
INSERT_BREADCRUMB_EXTRA_LEVEL: ({ newLevelName, previousLevelUrl, }: InsertOnBreadcrumbParams) => Message; | ||
CLEAR_BREADCRUMB_EXTRA_LEVELS: () => Message; | ||
}; |
@@ -0,1 +1,2 @@ | ||
import { ACTION_TYPES } from "./actions"; | ||
export interface CommonParams { | ||
@@ -23,1 +24,12 @@ /** | ||
} | ||
export interface Message { | ||
action: { | ||
type: ACTION_TYPES; | ||
newLevelName?: string; | ||
previousLevelUrl?: string; | ||
}; | ||
} | ||
export interface ReceivedMessage { | ||
origin: string; | ||
data?: Message; | ||
} |
{ | ||
"name": "admin-shell-messaging", | ||
"version": "0.1.3", | ||
"version": "0.1.4", | ||
"description": "Admin shell Iframe messaging package", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -1,2 +0,2 @@ | ||
import { InsertOnBreadcrumbParams } from "./types"; | ||
import { InsertOnBreadcrumbParams, Message } from "./types"; | ||
@@ -11,6 +11,6 @@ export enum ACTION_TYPES { | ||
export const ACTIONS = { | ||
START_LOADING: () => ({ | ||
START_LOADING: (): Message => ({ | ||
action: { type: ACTION_TYPES.START_LOADING }, | ||
}), | ||
STOP_LOADING: () => ({ | ||
STOP_LOADING: (): Message => ({ | ||
action: { type: ACTION_TYPES.STOP_LOADING }, | ||
@@ -21,3 +21,3 @@ }), | ||
previousLevelUrl = window.location.pathname, | ||
}: InsertOnBreadcrumbParams) => ({ | ||
}: InsertOnBreadcrumbParams): Message => ({ | ||
action: { | ||
@@ -29,3 +29,3 @@ type: ACTION_TYPES.INSERT_BREADCRUMB_EXTRA_LEVEL, | ||
}), | ||
CLEAR_BREADCRUMB_EXTRA_LEVELS: () => ({ | ||
CLEAR_BREADCRUMB_EXTRA_LEVELS: (): Message => ({ | ||
action: { | ||
@@ -32,0 +32,0 @@ type: ACTION_TYPES.CLEAR_BREADCRUMB_EXTRA_LEVELS, |
@@ -0,1 +1,3 @@ | ||
import { ACTION_TYPES } from "./actions"; | ||
export interface CommonParams { | ||
@@ -24,1 +26,14 @@ /** | ||
} | ||
export interface Message { | ||
action: { | ||
type: ACTION_TYPES; | ||
newLevelName?: string; | ||
previousLevelUrl?: string; | ||
}; | ||
} | ||
export interface ReceivedMessage { | ||
origin: string; | ||
data?: Message; | ||
} |
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
28491
846