@abyss-project/commons-front-core 20.1.0 → 20.3.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 +13 -0
- package/catalog/catalog-entries.ts +3 -0
- package/catalog/pages/QuotaReachedDialog.tsx +38 -0
- package/catalog/pages/index.ts +2 -0
- package/dist/{CookieConsentSettings-iQ9XTosT.js → CookieConsentSettings-BPBNaNNI.js} +258 -236
- package/dist/components/business/QuotaReachedDialog/QuotaReachedDialog.d.ts +13 -0
- package/dist/components/business/QuotaReachedDialog/QuotaReachedDialog.spec.d.ts +1 -0
- package/dist/components/business/index.d.ts +1 -0
- package/dist/components/layers/Toast/dialog-foot-clearance.d.ts +2 -2
- package/dist/components/layers/Toast/toast-clearance-registry.d.ts +14 -0
- package/dist/components/layers/Toast/toast-clearance.d.ts +4 -3
- package/dist/cookie-consent.js +1 -1
- package/dist/{design-theme--v6CDR8w.js → design-theme-HWymeGb7.js} +3396 -3396
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/use-toast-clearance.hook.d.ts +14 -0
- package/dist/hooks/use-toast-clearance.hook.spec.d.ts +1 -0
- package/dist/index.js +3923 -3838
- package/dist/legacy.js +4 -4
- package/package.json +3 -3
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export interface QuotaReachedDialogProps {
|
|
2
|
+
/**
|
|
3
|
+
* Called after the dialog is hidden, from the upgrade button; the host decides where to send the
|
|
4
|
+
* user. Without it the dialog has no upgrade button.
|
|
5
|
+
*/
|
|
6
|
+
onUpgrade?(): void;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* The "quota reached" dialog of every Abyss front: mounted once at the app root, it opens when the
|
|
10
|
+
* billing-quota interceptor pushes a payload into `useQuotaDialogStore`, and names the blocked
|
|
11
|
+
* service and metric.
|
|
12
|
+
*/
|
|
13
|
+
export declare const QuotaReachedDialog: ({ onUpgrade }: QuotaReachedDialogProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -2,6 +2,7 @@ export * from './InfectedDownloadModal/InfectedDownloadModal';
|
|
|
2
2
|
export * from './CloudImport/CloudImport';
|
|
3
3
|
export * from './ImportFromCloudModal/ImportFromCloudModal';
|
|
4
4
|
export * from './QRCodeModal/QRCodeModal';
|
|
5
|
+
export * from './QuotaReachedDialog/QuotaReachedDialog';
|
|
5
6
|
export * from './CookieConsent/AbyssCookieConsentProvider';
|
|
6
7
|
export * from './CookieConsent/CookieConsentBanner';
|
|
7
8
|
export * from './CookieConsent/CookieConsentSettings';
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
export declare const dialogFootClearance: (restingTop: number) => number;
|
|
13
13
|
/**
|
|
14
14
|
* While `active`, keeps `DIALOG_FOOT_CLEARANCE_VAR` on the toast region up to date. The variable
|
|
15
|
-
* lives on the region alone: `--abyss-toast-clearance`
|
|
16
|
-
* banner, which removes
|
|
15
|
+
* lives on the region alone: `--abyss-toast-clearance` belongs to the clearance registry (the largest
|
|
16
|
+
* claim, banner included) and the modal clearance to the cookie banner, which removes it when it leaves. The region stays a child of `body`, so nothing here
|
|
17
17
|
* depends on what the surface's style does to `position: fixed`.
|
|
18
18
|
*/
|
|
19
19
|
export declare const useDialogFootClearance: (region: HTMLElement | null, active: boolean) => void;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The distances, in px, that the things fixed to the bottom of the viewport claim for the toast
|
|
3
|
+
* region. Each caller owns one symbol key; the value published on `--abyss-toast-clearance` is the
|
|
4
|
+
* largest current claim, and the property is removed when no claim is left. Releasing a key never
|
|
5
|
+
* erases another caller's claim.
|
|
6
|
+
*/
|
|
7
|
+
export declare class ToastClearanceRegistry {
|
|
8
|
+
private readonly claims;
|
|
9
|
+
claim(key: symbol, distance: number): void;
|
|
10
|
+
release(key: symbol): void;
|
|
11
|
+
private publish;
|
|
12
|
+
}
|
|
13
|
+
/** The one registry of the page: the variable it writes lives on the document root. */
|
|
14
|
+
export declare const toastClearanceRegistry: ToastClearanceRegistry;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* The distance, from the bottom of the viewport, up to the top of
|
|
3
|
-
*
|
|
4
|
-
*
|
|
2
|
+
* The distance, from the bottom of the viewport, up to the top of the highest thing that already
|
|
3
|
+
* occupies the bottom (the cookie-consent banner, a screen's fixed bar): the largest claim of the
|
|
4
|
+
* clearance registry, written by it alone. The toast region keeps above it, so a notification never
|
|
5
|
+
* covers them. Unset while nothing claims.
|
|
5
6
|
*/
|
|
6
7
|
export declare const TOAST_CLEARANCE_VAR = "--abyss-toast-clearance";
|
|
7
8
|
/**
|
package/dist/cookie-consent.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as o, g as a, h as n, e as C, i as t, f as i, j as r, k as A, C as E, b as O, c as S, D as _, R as k, o as I, m as c, l as d, n as N, r as T, p as l, u as f, d as D, a as R, w as V } from "./CookieConsentSettings-
|
|
1
|
+
import { A as o, g as a, h as n, e as C, i as t, f as i, j as r, k as A, C as E, b as O, c as S, D as _, R as k, o as I, m as c, l as d, n as N, r as T, p as l, u as f, d as D, a as R, w as V } from "./CookieConsentSettings-BPBNaNNI.js";
|
|
2
2
|
import { f as p } from "./Surface-DmHRzUtQ.js";
|
|
3
3
|
export {
|
|
4
4
|
o as AbyssCookieConsentProvider,
|