@easy-cookie/core 0.1.0 → 0.1.2

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/dist/shared.cjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! @easy-cookie/core 0.1.0 | MIT | includes vanilla-cookieconsent v3.3.0 (c) Orest Bida, MIT */
1
+ /*! @easy-cookie/core 0.1.2 | MIT | includes vanilla-cookieconsent v3.3.0 (c) Orest Bida, MIT */
2
2
  "use strict";
3
3
  var __defProp = Object.defineProperty;
4
4
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
package/dist/shared.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { T as Texts, G as GcmSignal, a as CategoryDeclaration, L as Localized, g as EasyCookieConfig, d as ConsentMethod, f as ConsentState } from './types-CvWqxzmv.cjs';
2
- export { b as ConsentEventDetail, c as ConsentLogOptions, e as ConsentRecordInput, C as CookieDeclaration, D as DeepPartial, E as EasyCookieApi, h as EasyCookieEvent, i as GoogleConsentModeOptions, R as ReopenButtonOptions, S as ServiceDeclaration, U as UiOptions, j as UiPosition } from './types-CvWqxzmv.cjs';
1
+ import { T as Texts, G as GcmSignal, a as CategoryDeclaration, L as Localized, g as EasyCookieConfig, d as ConsentMethod, f as ConsentState } from './types-B6QEQkj-.cjs';
2
+ export { b as ConsentEventDetail, c as ConsentLogOptions, e as ConsentRecordInput, C as CookieDeclaration, D as DeepPartial, E as EasyCookieApi, h as EasyCookieEvent, i as GoogleConsentModeOptions, R as ReopenButtonOptions, S as ServiceDeclaration, U as UiOptions, j as UiPosition } from './types-B6QEQkj-.cjs';
3
3
 
4
4
  declare const DEFAULT_COOKIE_NAME = "ec_consent";
5
5
  declare const DEFAULT_EXPIRY_DAYS = 182;
package/dist/shared.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { T as Texts, G as GcmSignal, a as CategoryDeclaration, L as Localized, g as EasyCookieConfig, d as ConsentMethod, f as ConsentState } from './types-CvWqxzmv.js';
2
- export { b as ConsentEventDetail, c as ConsentLogOptions, e as ConsentRecordInput, C as CookieDeclaration, D as DeepPartial, E as EasyCookieApi, h as EasyCookieEvent, i as GoogleConsentModeOptions, R as ReopenButtonOptions, S as ServiceDeclaration, U as UiOptions, j as UiPosition } from './types-CvWqxzmv.js';
1
+ import { T as Texts, G as GcmSignal, a as CategoryDeclaration, L as Localized, g as EasyCookieConfig, d as ConsentMethod, f as ConsentState } from './types-B6QEQkj-.js';
2
+ export { b as ConsentEventDetail, c as ConsentLogOptions, e as ConsentRecordInput, C as CookieDeclaration, D as DeepPartial, E as EasyCookieApi, h as EasyCookieEvent, i as GoogleConsentModeOptions, R as ReopenButtonOptions, S as ServiceDeclaration, U as UiOptions, j as UiPosition } from './types-B6QEQkj-.js';
3
3
 
4
4
  declare const DEFAULT_COOKIE_NAME = "ec_consent";
5
5
  declare const DEFAULT_EXPIRY_DAYS = 182;
package/dist/shared.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @easy-cookie/core 0.1.0 | MIT | includes vanilla-cookieconsent v3.3.0 (c) Orest Bida, MIT */
1
+ /*! @easy-cookie/core 0.1.2 | MIT | includes vanilla-cookieconsent v3.3.0 (c) Orest Bida, MIT */
2
2
  import {
3
3
  DEFAULT_COOKIE_NAME,
4
4
  DEFAULT_EXPIRY_DAYS,
@@ -19,7 +19,7 @@ import {
19
19
  resolveConfig,
20
20
  resolveTexts,
21
21
  validateConfig
22
- } from "./chunk-5YF2UROU.js";
22
+ } from "./chunk-DBOJSPOI.js";
23
23
  export {
24
24
  DEFAULT_COOKIE_NAME,
25
25
  DEFAULT_EXPIRY_DAYS,
@@ -221,8 +221,12 @@ interface EasyCookieApi {
221
221
  rejectAll(): void;
222
222
  /** Accept exactly these categories (necessary ones are always included). */
223
223
  accept(categories: string[], services?: Record<string, string[]>): void;
224
- /** Link the anonymous consent id to a user id on the consent server (after login). */
225
- identify(subjectId: string): Promise<void>;
224
+ /**
225
+ * Link the anonymous consent id to a user id on the consent server (after login).
226
+ * Resolves true once the server confirmed the link. Before the visitor's first
227
+ * choice it resolves false and the link is made right after that choice.
228
+ */
229
+ identify(subjectId: string): Promise<boolean>;
226
230
  /** Forget the stored choice and show the banner again. */
227
231
  reset(): void;
228
232
  /** Resolved config (after run). */
@@ -221,8 +221,12 @@ interface EasyCookieApi {
221
221
  rejectAll(): void;
222
222
  /** Accept exactly these categories (necessary ones are always included). */
223
223
  accept(categories: string[], services?: Record<string, string[]>): void;
224
- /** Link the anonymous consent id to a user id on the consent server (after login). */
225
- identify(subjectId: string): Promise<void>;
224
+ /**
225
+ * Link the anonymous consent id to a user id on the consent server (after login).
226
+ * Resolves true once the server confirmed the link. Before the visitor's first
227
+ * choice it resolves false and the link is made right after that choice.
228
+ */
229
+ identify(subjectId: string): Promise<boolean>;
226
230
  /** Forget the stored choice and show the banner again. */
227
231
  reset(): void;
228
232
  /** Resolved config (after run). */
package/package.json CHANGED
@@ -1,8 +1,16 @@
1
1
  {
2
2
  "name": "@easy-cookie/core",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Self-hosted, GDPR/ePrivacy-compliant cookie consent: banner, prior blocking, Google Consent Mode v2, proof of consent.",
5
5
  "license": "MIT",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "git+https://github.com/Aleloca/easy-cookie.git",
9
+ "directory": "packages/core"
10
+ },
11
+ "bugs": {
12
+ "url": "https://github.com/Aleloca/easy-cookie/issues"
13
+ },
6
14
  "type": "module",
7
15
  "sideEffects": [
8
16
  "*.css"