@blateral/b.kit 2.0.0-beta.23.3 → 2.0.0-beta.24.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/lib/components/base/Section.d.ts +5 -3
- package/lib/components/base/Section.d.ts.map +1 -1
- package/lib/components/blocks/CookieConsent.d.ts +25 -21
- package/lib/components/blocks/CookieConsent.d.ts.map +1 -1
- package/lib/components/blocks/PromotionCard.d.ts.map +1 -1
- package/lib/components/fields/Checkbox.d.ts.map +1 -1
- package/lib/components/sections/Intro.d.ts.map +1 -1
- package/lib/components/sections/Teaser.d.ts.map +1 -1
- package/lib/components/sections/TeaserWide.d.ts.map +1 -1
- package/lib/components/sections/header/Header.d.ts.map +1 -1
- package/lib/components/sections/header/HeaderVideo.d.ts.map +1 -1
- package/lib/index.d.ts +7 -3
- package/lib/index.d.ts.map +1 -1
- package/lib/index.es.js +1 -1
- package/lib/index.es.js.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/utils/cookie-consent/cookie.d.ts +3 -3
- package/lib/utils/cookie-consent/cookie.d.ts.map +1 -1
- package/lib/utils/cookie-consent/mutations.d.ts +3 -2
- package/lib/utils/cookie-consent/mutations.d.ts.map +1 -1
- package/lib/utils/cookie-consent/useCookieConsent.d.ts +32 -0
- package/lib/utils/cookie-consent/useCookieConsent.d.ts.map +1 -0
- package/package.json +1 -1
- package/lib/components/buttons/QuicknavButton.d.ts +0 -10
- package/lib/components/buttons/QuicknavButton.d.ts.map +0 -1
- package/lib/components/sections/Quicknav.d.ts +0 -29
- package/lib/components/sections/Quicknav.d.ts.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export interface Cookie<T> {
|
|
1
|
+
export interface Cookie<T extends object> {
|
|
2
2
|
name: string;
|
|
3
3
|
data: T;
|
|
4
4
|
}
|
|
5
|
-
export declare const setCookie: <T>({ name, data, days, path, }: {
|
|
5
|
+
export declare const setCookie: <T extends object>({ name, data, days, path, }: {
|
|
6
6
|
name: string;
|
|
7
7
|
data: T;
|
|
8
8
|
days?: number | undefined;
|
|
9
9
|
path?: string | undefined;
|
|
10
10
|
}) => void;
|
|
11
|
-
export declare const getCookie: <T>(name: string) => Cookie<T> | undefined;
|
|
11
|
+
export declare const getCookie: <T extends object>(name: string) => Cookie<T> | undefined;
|
|
12
12
|
export declare const deleteCookie: (name: string) => void;
|
|
13
13
|
//# sourceMappingURL=cookie.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cookie.d.ts","sourceRoot":"","sources":["../../../src/utils/cookie-consent/cookie.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"cookie.d.ts","sourceRoot":"","sources":["../../../src/utils/cookie-consent/cookie.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM,CAAC,CAAC,SAAS,MAAM;IACpC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,CAAC,CAAC;CACX;AAED,eAAO,MAAM,SAAS;UAMZ,MAAM;;;;UAwBf,CAAC;AAEF,eAAO,MAAM,SAAS,2BACZ,MAAM,0BAuBf,CAAC;AAEF,eAAO,MAAM,YAAY,SAAU,MAAM,SAExC,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { CookieConsentData } from "../../components/blocks/CookieConsent";
|
|
2
1
|
import { Cookie } from './cookie';
|
|
2
|
+
import { CookieConsentData } from './useCookieConsent';
|
|
3
3
|
export declare const isUrlInWhitelist: (urlString: string, whitelist?: string[]) => boolean;
|
|
4
4
|
export declare const bindConsentButtons: (callback: () => void) => void;
|
|
5
|
-
export declare const activateTrackingScripts: () => void;
|
|
5
|
+
export declare const activateTrackingScripts: (scriptTypeSelectors?: string[]) => void;
|
|
6
6
|
export declare const updateConsentStatusElements: ({ cookie, status, dateFormat, timeFormat, localeKey, }: {
|
|
7
7
|
cookie: Cookie<CookieConsentData>;
|
|
8
8
|
status: string;
|
|
@@ -10,4 +10,5 @@ export declare const updateConsentStatusElements: ({ cookie, status, dateFormat,
|
|
|
10
10
|
timeFormat: string;
|
|
11
11
|
localeKey: 'de' | 'en';
|
|
12
12
|
}) => void;
|
|
13
|
+
export declare const updateConsentStatus: (content: string) => void;
|
|
13
14
|
//# sourceMappingURL=mutations.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mutations.d.ts","sourceRoot":"","sources":["../../../src/utils/cookie-consent/mutations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"mutations.d.ts","sourceRoot":"","sources":["../../../src/utils/cookie-consent/mutations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAElC,OAAO,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAEvD,eAAO,MAAM,gBAAgB,cACd,MAAM,cACN,MAAM,EAAE,YAUtB,CAAC;AAEF,eAAO,MAAM,kBAAkB,aAAc,MAAM,IAAI,SAQtD,CAAC;AAEF,eAAO,MAAM,uBAAuB,yBAAyB,MAAM,EAAE,SA2CpE,CAAC;AAEF,eAAO,MAAM,2BAA2B;YAO5B,OAAO,iBAAiB,CAAC;YACzB,MAAM;gBACF,MAAM;gBACN,MAAM;eACP,IAAI,GAAG,IAAI;UAkBzB,CAAC;AAEF,eAAO,MAAM,mBAAmB,YAAa,MAAM,SAUlD,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Cookie } from './cookie';
|
|
3
|
+
export interface CookieType {
|
|
4
|
+
label: string;
|
|
5
|
+
isAccepted: boolean;
|
|
6
|
+
isEditable: boolean;
|
|
7
|
+
}
|
|
8
|
+
export interface CookieTypes {
|
|
9
|
+
[key: string]: CookieType;
|
|
10
|
+
}
|
|
11
|
+
export interface CookieConsentData {
|
|
12
|
+
types: Record<string, boolean>;
|
|
13
|
+
updatedAt: number;
|
|
14
|
+
}
|
|
15
|
+
export interface CookieConsentSettings {
|
|
16
|
+
cookieName?: string;
|
|
17
|
+
initialCookieTypes?: CookieTypes;
|
|
18
|
+
lifetime?: number;
|
|
19
|
+
}
|
|
20
|
+
declare const useCookieConsent: (props: CookieConsentSettings, onSubmit?: (() => void) | undefined, statusRenderer?: ((props: {
|
|
21
|
+
updatedAt: number;
|
|
22
|
+
state: CookieTypes;
|
|
23
|
+
}) => React.ReactElement) | undefined) => {
|
|
24
|
+
cookieTypes: CookieTypes;
|
|
25
|
+
acceptAll: () => void;
|
|
26
|
+
acceptSelected: () => void;
|
|
27
|
+
declineAll: () => void;
|
|
28
|
+
setConsent: (type: keyof CookieTypes, isAccepted?: boolean | undefined) => void;
|
|
29
|
+
getCookieValue: () => Cookie<CookieConsentData> | undefined;
|
|
30
|
+
};
|
|
31
|
+
export default useCookieConsent;
|
|
32
|
+
//# sourceMappingURL=useCookieConsent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useCookieConsent.d.ts","sourceRoot":"","sources":["../../../src/utils/cookie-consent/useCookieConsent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoD,MAAM,OAAO,CAAC;AAGzE,OAAO,EAAE,MAAM,EAAwB,MAAM,UAAU,CAAC;AAGxD,MAAM,WAAW,UAAU;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,OAAO,CAAC;CACvB;AAED,MAAM,WAAW,WAAW;IACxB,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAAC;CAC7B;AAED,MAAM,WAAW,iBAAiB;IAC9B,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC/B,SAAS,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,qBAAqB;IAClC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,kBAAkB,CAAC,EAAE,WAAW,CAAC;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,QAAA,MAAM,gBAAgB,UACX,qBAAqB,oBACX,IAAI,yCACI;IACrB,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,WAAW,CAAC;CACtB,KAAK,MAAM,YAAY;;;;;uBAgKE,MAAM,WAAW;0BAehB,OAAO,iBAAiB,CAAC,GAAG,SAAS;CAYnE,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
declare const QuicknavButton: React.FC<{
|
|
3
|
-
link?: string;
|
|
4
|
-
label?: string;
|
|
5
|
-
isDisabled?: boolean;
|
|
6
|
-
isActive?: boolean;
|
|
7
|
-
isInverted?: boolean;
|
|
8
|
-
}>;
|
|
9
|
-
export default QuicknavButton;
|
|
10
|
-
//# sourceMappingURL=QuicknavButton.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"QuicknavButton.d.ts","sourceRoot":"","sources":["../../../src/components/buttons/QuicknavButton.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAyC/B,QAAA,MAAM,cAAc,EAAE,KAAK,CAAC,EAAE,CAAC;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;CACxB,CAaA,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
export declare const QuicknavComponent: React.FC<{
|
|
3
|
-
/** ID value for targeting section with anchor hashes */
|
|
4
|
-
anchorId?: string | undefined;
|
|
5
|
-
navItems: {
|
|
6
|
-
label: string;
|
|
7
|
-
link?: string;
|
|
8
|
-
}[];
|
|
9
|
-
activeNavItem?: string | undefined;
|
|
10
|
-
onNavClick?: ((index: number, label: string) => void) | undefined;
|
|
11
|
-
className?: string | undefined;
|
|
12
|
-
bgMode?: "inverted" | undefined;
|
|
13
|
-
}>;
|
|
14
|
-
declare const _default: React.FC<{
|
|
15
|
-
/** ID value for targeting section with anchor hashes */
|
|
16
|
-
anchorId?: string | undefined;
|
|
17
|
-
navItems: {
|
|
18
|
-
label: string;
|
|
19
|
-
link?: string | undefined;
|
|
20
|
-
}[];
|
|
21
|
-
activeNavItem?: string | undefined;
|
|
22
|
-
onNavClick?: ((index: number, label: string) => void) | undefined;
|
|
23
|
-
className?: string | undefined;
|
|
24
|
-
bgMode?: "inverted" | undefined;
|
|
25
|
-
} & {
|
|
26
|
-
theme?: import("../../utils/types").RecursivePartial<import("styled-components").DefaultTheme> | undefined;
|
|
27
|
-
}>;
|
|
28
|
-
export default _default;
|
|
29
|
-
//# sourceMappingURL=Quicknav.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Quicknav.d.ts","sourceRoot":"","sources":["../../../src/components/sections/Quicknav.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAmK/B,eAAO,MAAM,iBAAiB;IA/F1B,wDAAwD;;cAG9C;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE;;0BAEvB,MAAM,SAAS,MAAM,KAAK,IAAI;;;EA0Fd,CAAC;;IA/FtC,wDAAwD;;;;;;;;;;;;;AAgG5D,wBAAsC"}
|