@trackunit/react-core-hooks
Advanced tools
Comparing version 0.2.268-alpha-6a33ca13ab4.0 to 0.2.269
@@ -372,5 +372,5 @@ 'use strict'; | ||
const OemBrandingContext = React.createContext(null); | ||
const OEMBrandingService = React.createContext(null); | ||
/** | ||
* This is a hook to use the IOemBrandingContext. | ||
* This is a hook to use the OemBrandingContext. | ||
* | ||
@@ -383,6 +383,6 @@ * @requires OemBrandingContextProvider | ||
* const branding = getOemBranding("some brand") | ||
* @see {@link IOemBrandingContext} | ||
* @see {@link OemBrandingContext} | ||
*/ | ||
const useOemBrandingContext = () => { | ||
const context = React.useContext(OemBrandingContext); | ||
const context = React.useContext(OEMBrandingService); | ||
if (!context) { | ||
@@ -394,6 +394,6 @@ throw new Error("useOemBranding must be used within an OemBrandingContextProvider"); | ||
/** | ||
* This is a provider for the IOemBrandingContext. | ||
* This is a provider for the OemBrandingContext. | ||
*/ | ||
const OemBrandingContextProvider = (props) => { | ||
return jsxRuntime.jsx(OemBrandingContext.Provider, { ...props }); | ||
return jsxRuntime.jsx(OEMBrandingService.Provider, { ...props }); | ||
}; | ||
@@ -400,0 +400,0 @@ |
@@ -352,5 +352,5 @@ import * as React from 'react'; | ||
const OemBrandingContext = createContext(null); | ||
const OEMBrandingService = createContext(null); | ||
/** | ||
* This is a hook to use the IOemBrandingContext. | ||
* This is a hook to use the OemBrandingContext. | ||
* | ||
@@ -363,6 +363,6 @@ * @requires OemBrandingContextProvider | ||
* const branding = getOemBranding("some brand") | ||
* @see {@link IOemBrandingContext} | ||
* @see {@link OemBrandingContext} | ||
*/ | ||
const useOemBrandingContext = () => { | ||
const context = useContext(OemBrandingContext); | ||
const context = useContext(OEMBrandingService); | ||
if (!context) { | ||
@@ -374,6 +374,6 @@ throw new Error("useOemBranding must be used within an OemBrandingContextProvider"); | ||
/** | ||
* This is a provider for the IOemBrandingContext. | ||
* This is a provider for the OemBrandingContext. | ||
*/ | ||
const OemBrandingContextProvider = (props) => { | ||
return jsx(OemBrandingContext.Provider, { ...props }); | ||
return jsx(OEMBrandingService.Provider, { ...props }); | ||
}; | ||
@@ -380,0 +380,0 @@ |
{ | ||
"name": "@trackunit/react-core-hooks", | ||
"version": "0.2.268-alpha-6a33ca13ab4.0", | ||
"version": "0.2.269", | ||
"repository": "https://github.com/Trackunit/manager", | ||
@@ -5,0 +5,0 @@ "license": "SEE LICENSE IN LICENSE.txt", |
@@ -1,4 +0,4 @@ | ||
import { IOemBrandingContext } from "@trackunit/react-core-contexts-api"; | ||
import { OemBrandingContext } from "@trackunit/react-core-contexts-api"; | ||
/** | ||
* This is a hook to use the IOemBrandingContext. | ||
* This is a hook to use the OemBrandingContext. | ||
* | ||
@@ -11,13 +11,13 @@ * @requires OemBrandingContextProvider | ||
* const branding = getOemBranding("some brand") | ||
* @see {@link IOemBrandingContext} | ||
* @see {@link OemBrandingContext} | ||
*/ | ||
export declare const useOemBrandingContext: () => IOemBrandingContext; | ||
interface IProps { | ||
value: IOemBrandingContext; | ||
export declare const useOemBrandingContext: () => OemBrandingContext; | ||
interface OemBrandingContextProviderProps { | ||
value: OemBrandingContext; | ||
children?: React.ReactNode; | ||
} | ||
/** | ||
* This is a provider for the IOemBrandingContext. | ||
* This is a provider for the OemBrandingContext. | ||
*/ | ||
export declare const OemBrandingContextProvider: (props: IProps) => import("react/jsx-runtime").JSX.Element; | ||
export declare const OemBrandingContextProvider: (props: OemBrandingContextProviderProps) => import("react/jsx-runtime").JSX.Element; | ||
export {}; |
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
101933
0