@react-spectrum/toast 3.0.0-beta.11 → 3.0.0-beta.13
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/Toast.main.js +24 -20
- package/dist/Toast.main.js.map +1 -1
- package/dist/Toast.mjs +27 -23
- package/dist/Toast.module.js +26 -22
- package/dist/Toast.module.js.map +1 -1
- package/dist/ToastContainer.main.js +18 -9
- package/dist/ToastContainer.main.js.map +1 -1
- package/dist/ToastContainer.mjs +23 -10
- package/dist/ToastContainer.module.js +22 -9
- package/dist/ToastContainer.module.js.map +1 -1
- package/dist/Toaster.main.js +9 -8
- package/dist/Toaster.main.js.map +1 -1
- package/dist/Toaster.mjs +10 -8
- package/dist/Toaster.module.js +9 -7
- package/dist/Toaster.module.js.map +1 -1
- package/dist/ar-AE.mjs +1 -1
- package/dist/bg-BG.mjs +1 -1
- package/dist/cs-CZ.mjs +1 -1
- package/dist/da-DK.mjs +1 -1
- package/dist/de-DE.mjs +1 -1
- package/dist/el-GR.mjs +1 -1
- package/dist/en-US.mjs +1 -1
- package/dist/es-ES.mjs +1 -1
- package/dist/et-EE.mjs +1 -1
- package/dist/fi-FI.mjs +1 -1
- package/dist/fr-FR.mjs +1 -1
- package/dist/he-IL.mjs +1 -1
- package/dist/hr-HR.mjs +1 -1
- package/dist/hu-HU.mjs +1 -1
- package/dist/intlStrings.mjs +1 -1
- package/dist/it-IT.mjs +1 -1
- package/dist/ja-JP.mjs +1 -1
- package/dist/ko-KR.mjs +1 -1
- package/dist/lt-LT.mjs +1 -1
- package/dist/lv-LV.mjs +1 -1
- package/dist/nb-NO.mjs +1 -1
- package/dist/nl-NL.mjs +1 -1
- package/dist/pl-PL.mjs +1 -1
- package/dist/pt-BR.mjs +1 -1
- package/dist/pt-PT.mjs +1 -1
- package/dist/ro-RO.mjs +1 -1
- package/dist/ru-RU.mjs +1 -1
- package/dist/sk-SK.mjs +1 -1
- package/dist/sl-SI.mjs +1 -1
- package/dist/sr-SP.mjs +1 -1
- package/dist/sv-SE.mjs +1 -1
- package/dist/{toastContainer.b596792c.css → toastContainer.da404f80.css} +27 -3
- package/dist/toastContainer.da404f80.css.map +1 -0
- package/dist/toastContainer_css.main.js +16 -7
- package/dist/toastContainer_css.main.js.map +1 -1
- package/dist/toastContainer_css.mjs +17 -8
- package/dist/toastContainer_css.module.js +16 -7
- package/dist/toastContainer_css.module.js.map +1 -1
- package/dist/toast_vars_css.mjs +1 -1
- package/dist/tr-TR.mjs +1 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/uk-UA.mjs +1 -1
- package/dist/{vars.85cde188.css → vars.c6e65b7e.css} +4 -7
- package/dist/vars.c6e65b7e.css.map +1 -0
- package/dist/zh-CN.mjs +1 -1
- package/dist/zh-TW.mjs +1 -1
- package/package.json +14 -14
- package/src/Toast.tsx +27 -22
- package/src/ToastContainer.tsx +15 -7
- package/src/Toaster.tsx +18 -15
- package/src/toastContainer.css +32 -2
- package/dist/toastContainer.b596792c.css.map +0 -1
- package/dist/vars.85cde188.css.map +0 -1
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
import {Toast as $7e7a2952509f3a56$export$8d8dc7d5f743331b} from "./Toast.module.js";
|
|
2
|
+
import "./toastContainer.da404f80.css";
|
|
3
|
+
import $5lmgI$toastContainer_cssmodulejs from "./toastContainer_css.module.js";
|
|
2
4
|
import {Toaster as $e46feef4e4c28a4b$export$fb98e3a2a4cd92d7} from "./Toaster.module.js";
|
|
5
|
+
import {classNames as $5lmgI$classNames} from "@react-spectrum/utils";
|
|
3
6
|
import {filterDOMProps as $5lmgI$filterDOMProps} from "@react-aria/utils";
|
|
4
7
|
import $5lmgI$react, {useRef as $5lmgI$useRef, useEffect as $5lmgI$useEffect} from "react";
|
|
5
8
|
import {ToastQueue as $5lmgI$ToastQueue, useToastQueue as $5lmgI$useToastQueue} from "@react-stately/toast";
|
|
6
9
|
import {useSyncExternalStore as $5lmgI$useSyncExternalStore} from "use-sync-external-store/shim/index.js";
|
|
7
10
|
|
|
11
|
+
|
|
12
|
+
function $parcel$interopDefault(a) {
|
|
13
|
+
return a && a.__esModule ? a.default : a;
|
|
14
|
+
}
|
|
8
15
|
/*
|
|
9
16
|
* Copyright 2020 Adobe. All rights reserved.
|
|
10
17
|
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
|
|
@@ -21,6 +28,8 @@ import {useSyncExternalStore as $5lmgI$useSyncExternalStore} from "use-sync-exte
|
|
|
21
28
|
|
|
22
29
|
|
|
23
30
|
|
|
31
|
+
|
|
32
|
+
|
|
24
33
|
// There is a single global toast queue instance for the whole app, initialized lazily.
|
|
25
34
|
let $02c59b34bd70955a$var$globalToastQueue = null;
|
|
26
35
|
function $02c59b34bd70955a$var$getGlobalToastQueue() {
|
|
@@ -53,7 +62,7 @@ function $02c59b34bd70955a$export$f2815235e76a62b9(props) {
|
|
|
53
62
|
// Only the first one will actually render.
|
|
54
63
|
// We use a ref to do this, since it will have a stable identity
|
|
55
64
|
// over the lifetime of the component.
|
|
56
|
-
let ref = (0, $5lmgI$useRef)();
|
|
65
|
+
let ref = (0, $5lmgI$useRef)(undefined);
|
|
57
66
|
// eslint-disable-next-line arrow-body-style
|
|
58
67
|
(0, $5lmgI$useEffect)(()=>{
|
|
59
68
|
$02c59b34bd70955a$var$toastProviders.add(ref);
|
|
@@ -75,17 +84,21 @@ function $02c59b34bd70955a$export$f2815235e76a62b9(props) {
|
|
|
75
84
|
if (ref === activeToastContainer && state.visibleToasts.length > 0) return /*#__PURE__*/ (0, $5lmgI$react).createElement((0, $e46feef4e4c28a4b$export$fb98e3a2a4cd92d7), {
|
|
76
85
|
state: state,
|
|
77
86
|
...props
|
|
78
|
-
},
|
|
87
|
+
}, /*#__PURE__*/ (0, $5lmgI$react).createElement("ol", {
|
|
88
|
+
className: (0, $5lmgI$classNames)((0, ($parcel$interopDefault($5lmgI$toastContainer_cssmodulejs))), 'spectrum-ToastContainer-list')
|
|
89
|
+
}, state.visibleToasts.slice().reverse().map((toast)=>/*#__PURE__*/ (0, $5lmgI$react).createElement("li", {
|
|
79
90
|
key: toast.key,
|
|
91
|
+
className: (0, $5lmgI$classNames)((0, ($parcel$interopDefault($5lmgI$toastContainer_cssmodulejs))), 'spectrum-ToastContainer-listitem')
|
|
92
|
+
}, /*#__PURE__*/ (0, $5lmgI$react).createElement((0, $7e7a2952509f3a56$export$8d8dc7d5f743331b), {
|
|
80
93
|
toast: toast,
|
|
81
94
|
state: state
|
|
82
|
-
})));
|
|
95
|
+
})))));
|
|
83
96
|
return null;
|
|
84
97
|
}
|
|
85
98
|
function $02c59b34bd70955a$var$addToast(children, variant, options = {}) {
|
|
86
99
|
// Dispatch a custom event so that toasts can be intercepted and re-targeted, e.g. when inside an iframe.
|
|
87
|
-
if (typeof CustomEvent !==
|
|
88
|
-
let event = new CustomEvent(
|
|
100
|
+
if (typeof CustomEvent !== 'undefined' && typeof window !== 'undefined') {
|
|
101
|
+
let event = new CustomEvent('react-spectrum-toast', {
|
|
89
102
|
cancelable: true,
|
|
90
103
|
bubbles: true,
|
|
91
104
|
detail: {
|
|
@@ -118,16 +131,16 @@ function $02c59b34bd70955a$var$addToast(children, variant, options = {}) {
|
|
|
118
131
|
}
|
|
119
132
|
const $02c59b34bd70955a$export$f1f8569633bbbec4 = {
|
|
120
133
|
/** Queues a neutral toast. */ neutral (children, options = {}) {
|
|
121
|
-
return $02c59b34bd70955a$var$addToast(children,
|
|
134
|
+
return $02c59b34bd70955a$var$addToast(children, 'neutral', options);
|
|
122
135
|
},
|
|
123
136
|
/** Queues a positive toast. */ positive (children, options = {}) {
|
|
124
|
-
return $02c59b34bd70955a$var$addToast(children,
|
|
137
|
+
return $02c59b34bd70955a$var$addToast(children, 'positive', options);
|
|
125
138
|
},
|
|
126
139
|
/** Queues a negative toast. */ negative (children, options = {}) {
|
|
127
|
-
return $02c59b34bd70955a$var$addToast(children,
|
|
140
|
+
return $02c59b34bd70955a$var$addToast(children, 'negative', options);
|
|
128
141
|
},
|
|
129
142
|
/** Queues an informational toast. */ info (children, options = {}) {
|
|
130
|
-
return $02c59b34bd70955a$var$addToast(children,
|
|
143
|
+
return $02c59b34bd70955a$var$addToast(children, 'info', options);
|
|
131
144
|
}
|
|
132
145
|
};
|
|
133
146
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":"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","sources":["packages/@react-spectrum/toast/src/ToastContainer.tsx"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {AriaToastRegionProps} from '@react-aria/toast';\nimport {classNames} from '@react-spectrum/utils';\nimport {DOMProps} from '@react-types/shared';\nimport {filterDOMProps} from '@react-aria/utils';\nimport React, {ReactElement, useEffect, useRef} from 'react';\nimport {SpectrumToastValue, Toast} from './Toast';\nimport toastContainerStyles from './toastContainer.css';\nimport {Toaster} from './Toaster';\nimport {ToastOptions, ToastQueue, useToastQueue} from '@react-stately/toast';\nimport {useSyncExternalStore} from 'use-sync-external-store/shim/index.js';\n\nexport interface SpectrumToastContainerProps extends AriaToastRegionProps {}\n\nexport interface SpectrumToastOptions extends Omit<ToastOptions, 'priority'>, DOMProps {\n /** A label for the action button within the toast. */\n actionLabel?: string,\n /** Handler that is called when the action button is pressed. */\n onAction?: () => void,\n /** Whether the toast should automatically close when an action is performed. */\n shouldCloseOnAction?: boolean\n}\n\ntype CloseFunction = () => void;\n\n// There is a single global toast queue instance for the whole app, initialized lazily.\nlet globalToastQueue: ToastQueue<SpectrumToastValue> | null = null;\nfunction getGlobalToastQueue() {\n if (!globalToastQueue) {\n globalToastQueue = new ToastQueue({\n maxVisibleToasts: Infinity,\n hasExitAnimation: true\n });\n }\n\n return globalToastQueue;\n}\n\n// For testing. Not exported from the package index.\nexport function clearToastQueue() {\n globalToastQueue = null;\n}\n\nlet toastProviders = new Set();\nlet subscriptions = new Set<() => void>();\nfunction subscribe(fn: () => void) {\n subscriptions.add(fn);\n return () => subscriptions.delete(fn);\n}\n\nfunction triggerSubscriptions() {\n for (let fn of subscriptions) {\n fn();\n }\n}\n\nfunction getActiveToastContainer() {\n return toastProviders.values().next().value;\n}\n\nfunction useActiveToastContainer() {\n return useSyncExternalStore(subscribe, getActiveToastContainer, getActiveToastContainer);\n}\n\n/**\n * A ToastContainer renders the queued toasts in an application. It should be placed\n * at the root of the app.\n */\nexport function ToastContainer(props: SpectrumToastContainerProps): ReactElement {\n // Track all toast provider instances in a set.\n // Only the first one will actually render.\n // We use a ref to do this, since it will have a stable identity\n // over the lifetime of the component.\n let ref = useRef(undefined);\n\n // eslint-disable-next-line arrow-body-style\n useEffect(() => {\n toastProviders.add(ref);\n triggerSubscriptions();\n\n return () => {\n // When this toast provider unmounts, reset all animations so that\n // when the new toast provider renders, it is seamless.\n for (let toast of getGlobalToastQueue().visibleToasts) {\n toast.animation = null;\n }\n\n // Remove this toast provider, and call subscriptions.\n // This will cause all other instances to re-render,\n // and the first one to become the new active toast provider.\n toastProviders.delete(ref);\n triggerSubscriptions();\n };\n }, []);\n\n // Only render if this is the active toast provider instance, and there are visible toasts.\n let activeToastContainer = useActiveToastContainer();\n let state = useToastQueue(getGlobalToastQueue());\n\n if (ref === activeToastContainer && state.visibleToasts.length > 0) {\n return (\n <Toaster state={state} {...props}>\n <ol className={classNames(toastContainerStyles, 'spectrum-ToastContainer-list')}>\n {state.visibleToasts.slice().reverse().map((toast) => (\n <li\n key={toast.key}\n className={classNames(toastContainerStyles, 'spectrum-ToastContainer-listitem')}>\n <Toast\n toast={toast}\n state={state} />\n </li>\n ))}\n </ol>\n </Toaster>\n );\n }\n\n return null;\n}\n\nfunction addToast(children: string, variant: SpectrumToastValue['variant'], options: SpectrumToastOptions = {}) {\n // Dispatch a custom event so that toasts can be intercepted and re-targeted, e.g. when inside an iframe.\n if (typeof CustomEvent !== 'undefined' && typeof window !== 'undefined') {\n let event = new CustomEvent('react-spectrum-toast', {\n cancelable: true,\n bubbles: true,\n detail: {\n children,\n variant,\n options\n }\n });\n\n let shouldContinue = window.dispatchEvent(event);\n if (!shouldContinue) {\n return;\n }\n }\n\n let value = {\n children,\n variant,\n actionLabel: options.actionLabel,\n onAction: options.onAction,\n shouldCloseOnAction: options.shouldCloseOnAction,\n ...filterDOMProps(options)\n };\n\n // Minimum time of 5s from https://spectrum.adobe.com/page/toast/#Auto-dismissible\n // Actionable toasts cannot be auto dismissed. That would fail WCAG SC 2.2.1.\n // It is debatable whether non-actionable toasts would also fail.\n let timeout = options.timeout && !options.onAction ? Math.max(options.timeout, 5000) : null;\n let queue = getGlobalToastQueue();\n let key = queue.add(value, {timeout, onClose: options.onClose});\n return () => queue.close(key);\n}\n\nconst SpectrumToastQueue = {\n /** Queues a neutral toast. */\n neutral(children: string, options: SpectrumToastOptions = {}): CloseFunction {\n return addToast(children, 'neutral', options);\n },\n /** Queues a positive toast. */\n positive(children: string, options: SpectrumToastOptions = {}): CloseFunction {\n return addToast(children, 'positive', options);\n },\n /** Queues a negative toast. */\n negative(children: string, options: SpectrumToastOptions = {}): CloseFunction {\n return addToast(children, 'negative', options);\n },\n /** Queues an informational toast. */\n info(children: string, options: SpectrumToastOptions = {}): CloseFunction {\n return addToast(children, 'info', options);\n }\n};\n\nexport {SpectrumToastQueue as ToastQueue};\n"],"names":[],"version":3,"file":"ToastContainer.module.js.map"}
|
package/dist/Toaster.main.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
require("./toastContainer.
|
|
1
|
+
require("./toastContainer.da404f80.css");
|
|
2
2
|
var $e20782d0579ed886$exports = require("./toastContainer_css.main.js");
|
|
3
3
|
var $acAHv$reactariatoast = require("@react-aria/toast");
|
|
4
4
|
var $acAHv$reactspectrumutils = require("@react-spectrum/utils");
|
|
5
|
+
var $acAHv$reactariafocus = require("@react-aria/focus");
|
|
5
6
|
var $acAHv$reactariautils = require("@react-aria/utils");
|
|
6
7
|
var $acAHv$reactspectrumprovider = require("@react-spectrum/provider");
|
|
7
8
|
var $acAHv$react = require("react");
|
|
8
9
|
var $acAHv$reactdom = require("react-dom");
|
|
9
|
-
var $acAHv$reactariafocus = require("@react-aria/focus");
|
|
10
10
|
var $acAHv$reactariaoverlays = require("@react-aria/overlays");
|
|
11
11
|
|
|
12
12
|
|
|
@@ -18,7 +18,6 @@ function $parcel$export(e, n, v, s) {
|
|
|
18
18
|
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
$parcel$export(module.exports, "ToasterContext", () => $5b9f2c86c1b1395c$export$9194c0aa0cd7a9ff);
|
|
22
21
|
$parcel$export(module.exports, "Toaster", () => $5b9f2c86c1b1395c$export$fb98e3a2a4cd92d7);
|
|
23
22
|
/*
|
|
24
23
|
* Copyright 2020 Adobe. All rights reserved.
|
|
@@ -42,23 +41,25 @@ $parcel$export(module.exports, "Toaster", () => $5b9f2c86c1b1395c$export$fb98e3a
|
|
|
42
41
|
const $5b9f2c86c1b1395c$export$9194c0aa0cd7a9ff = /*#__PURE__*/ (0, $acAHv$react.createContext)(false);
|
|
43
42
|
function $5b9f2c86c1b1395c$export$fb98e3a2a4cd92d7(props) {
|
|
44
43
|
let { children: children, state: state } = props;
|
|
45
|
-
let ref = (0, $acAHv$react.useRef)();
|
|
44
|
+
let ref = (0, $acAHv$react.useRef)(undefined);
|
|
46
45
|
let { regionProps: regionProps } = (0, $acAHv$reactariatoast.useToastRegion)(props, state, ref);
|
|
47
46
|
let { focusProps: focusProps, isFocusVisible: isFocusVisible } = (0, $acAHv$reactariafocus.useFocusRing)();
|
|
48
47
|
let { getContainer: getContainer } = (0, $acAHv$reactariaoverlays.useUNSTABLE_PortalContext)();
|
|
49
48
|
let contents = /*#__PURE__*/ (0, ($parcel$interopDefault($acAHv$react))).createElement((0, $acAHv$reactspectrumprovider.Provider), {
|
|
50
49
|
UNSAFE_style: {
|
|
51
|
-
background:
|
|
50
|
+
background: 'transparent'
|
|
52
51
|
}
|
|
53
|
-
}, /*#__PURE__*/ (0, ($parcel$interopDefault($acAHv$react))).createElement($5b9f2c86c1b1395c$export$9194c0aa0cd7a9ff.Provider, {
|
|
52
|
+
}, /*#__PURE__*/ (0, ($parcel$interopDefault($acAHv$react))).createElement((0, $acAHv$reactariafocus.FocusScope), null, /*#__PURE__*/ (0, ($parcel$interopDefault($acAHv$react))).createElement($5b9f2c86c1b1395c$export$9194c0aa0cd7a9ff.Provider, {
|
|
54
53
|
value: isFocusVisible
|
|
55
54
|
}, /*#__PURE__*/ (0, ($parcel$interopDefault($acAHv$react))).createElement("div", {
|
|
56
55
|
...(0, $acAHv$reactariautils.mergeProps)(regionProps, focusProps),
|
|
57
56
|
ref: ref,
|
|
58
57
|
"data-position": "bottom",
|
|
59
58
|
"data-placement": "center",
|
|
60
|
-
className: (0, $acAHv$reactspectrumutils.classNames)((0, ($parcel$interopDefault($e20782d0579ed886$exports))),
|
|
61
|
-
|
|
59
|
+
className: (0, $acAHv$reactspectrumutils.classNames)((0, ($parcel$interopDefault($e20782d0579ed886$exports))), 'react-spectrum-ToastContainer', {
|
|
60
|
+
'focus-ring': isFocusVisible
|
|
61
|
+
})
|
|
62
|
+
}, children))));
|
|
62
63
|
var _getContainer;
|
|
63
64
|
return /*#__PURE__*/ (0, ($parcel$interopDefault($acAHv$reactdom))).createPortal(contents, (_getContainer = getContainer === null || getContainer === void 0 ? void 0 : getContainer()) !== null && _getContainer !== void 0 ? _getContainer : document.body);
|
|
64
65
|
}
|
package/dist/Toaster.main.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;AAkBM,MAAM,0DAAiB,CAAA,GAAA,0BAAY,EAAE;AAErC,SAAS,0CAAQ,KAA0B;IAChD,IAAI,YACF,QAAQ,SACR,KAAK,EACN,GAAG;IAEJ,IAAI,MAAM,CAAA,GAAA,mBAAK,EAAE;IACjB,IAAI,eAAC,WAAW,EAAC,GAAG,CAAA,GAAA,oCAAa,EAAE,OAAO,OAAO;IACjD,IAAI,cAAC,UAAU,kBAAE,cAAc,EAAC,GAAG,CAAA,GAAA,kCAAW;IAC9C,IAAI,gBAAC,YAAY,EAAC,GAAG,CAAA,GAAA,kDAAwB;IAE7C,IAAI,yBACF,0DAAC,CAAA,GAAA,qCAAO;QAAE,cAAc;YAAC,YAAY;QAAa;qBAChD,0DAAC,CAAA,GAAA,gCAAS,uBACR,0DAAC,0CAAe,QAAQ;QAAC,OAAO;qBAC9B,0DAAC;QACE,GAAG,CAAA,GAAA,gCAAS,EAAE,aAAa,WAAW;QACvC,KAAK;QACL,iBAAc;QACd,kBAAe;QACf,WAAW,CAAA,GAAA,oCAAS,EAClB,CAAA,GAAA,mDAAmB,GACnB,iCACA;YAAC,cAAc;QAAc;OAE9B;QAO4B;IAAvC,qBAAO,CAAA,GAAA,yCAAO,EAAE,YAAY,CAAC,UAAU,CAAA,gBAAA,yBAAA,mCAAA,4BAAA,2BAAA,gBAAoB,SAAS,IAAI;AAC1E","sources":["packages/@react-spectrum/toast/src/Toaster.tsx"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {AriaToastRegionProps, useToastRegion} from '@react-aria/toast';\nimport {classNames} from '@react-spectrum/utils';\nimport {FocusScope, useFocusRing} from '@react-aria/focus';\nimport {mergeProps} from '@react-aria/utils';\nimport {Provider} from '@react-spectrum/provider';\nimport React, {createContext, ReactElement, ReactNode, useRef} from 'react';\nimport ReactDOM from 'react-dom';\nimport toastContainerStyles from './toastContainer.css';\nimport {ToastState} from '@react-stately/toast';\nimport {useUNSTABLE_PortalContext} from '@react-aria/overlays';\n\ninterface ToastContainerProps extends AriaToastRegionProps {\n children: ReactNode,\n state: ToastState<unknown>\n}\n\nexport const ToasterContext = createContext(false);\n\nexport function Toaster(props: ToastContainerProps): ReactElement {\n let {\n children,\n state\n } = props;\n\n let ref = useRef(undefined);\n let {regionProps} = useToastRegion(props, state, ref);\n let {focusProps, isFocusVisible} = useFocusRing();\n let {getContainer} = useUNSTABLE_PortalContext();\n\n let contents = (\n <Provider UNSAFE_style={{background: 'transparent'}}>\n <FocusScope>\n <ToasterContext.Provider value={isFocusVisible}>\n <div\n {...mergeProps(regionProps, focusProps)}\n ref={ref}\n data-position=\"bottom\"\n data-placement=\"center\"\n className={classNames(\n toastContainerStyles,\n 'react-spectrum-ToastContainer',\n {'focus-ring': isFocusVisible}\n )}>\n {children}\n </div>\n </ToasterContext.Provider>\n </FocusScope>\n </Provider>\n );\n\n return ReactDOM.createPortal(contents, getContainer?.() ?? document.body);\n}\n"],"names":[],"version":3,"file":"Toaster.main.js.map"}
|
package/dist/Toaster.mjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "./toastContainer.
|
|
1
|
+
import "./toastContainer.da404f80.css";
|
|
2
2
|
import $7Pdp8$toastContainer_cssmodulejs from "./toastContainer_css.mjs";
|
|
3
3
|
import {useToastRegion as $7Pdp8$useToastRegion} from "@react-aria/toast";
|
|
4
4
|
import {classNames as $7Pdp8$classNames} from "@react-spectrum/utils";
|
|
5
|
+
import {useFocusRing as $7Pdp8$useFocusRing, FocusScope as $7Pdp8$FocusScope} from "@react-aria/focus";
|
|
5
6
|
import {mergeProps as $7Pdp8$mergeProps} from "@react-aria/utils";
|
|
6
7
|
import {Provider as $7Pdp8$Provider} from "@react-spectrum/provider";
|
|
7
8
|
import $7Pdp8$react, {createContext as $7Pdp8$createContext, useRef as $7Pdp8$useRef} from "react";
|
|
8
9
|
import $7Pdp8$reactdom from "react-dom";
|
|
9
|
-
import {useFocusRing as $7Pdp8$useFocusRing} from "@react-aria/focus";
|
|
10
10
|
import {useUNSTABLE_PortalContext as $7Pdp8$useUNSTABLE_PortalContext} from "@react-aria/overlays";
|
|
11
11
|
|
|
12
12
|
|
|
@@ -35,27 +35,29 @@ function $parcel$interopDefault(a) {
|
|
|
35
35
|
const $e46feef4e4c28a4b$export$9194c0aa0cd7a9ff = /*#__PURE__*/ (0, $7Pdp8$createContext)(false);
|
|
36
36
|
function $e46feef4e4c28a4b$export$fb98e3a2a4cd92d7(props) {
|
|
37
37
|
let { children: children, state: state } = props;
|
|
38
|
-
let ref = (0, $7Pdp8$useRef)();
|
|
38
|
+
let ref = (0, $7Pdp8$useRef)(undefined);
|
|
39
39
|
let { regionProps: regionProps } = (0, $7Pdp8$useToastRegion)(props, state, ref);
|
|
40
40
|
let { focusProps: focusProps, isFocusVisible: isFocusVisible } = (0, $7Pdp8$useFocusRing)();
|
|
41
41
|
let { getContainer: getContainer } = (0, $7Pdp8$useUNSTABLE_PortalContext)();
|
|
42
42
|
let contents = /*#__PURE__*/ (0, $7Pdp8$react).createElement((0, $7Pdp8$Provider), {
|
|
43
43
|
UNSAFE_style: {
|
|
44
|
-
background:
|
|
44
|
+
background: 'transparent'
|
|
45
45
|
}
|
|
46
|
-
}, /*#__PURE__*/ (0, $7Pdp8$react).createElement($e46feef4e4c28a4b$export$9194c0aa0cd7a9ff.Provider, {
|
|
46
|
+
}, /*#__PURE__*/ (0, $7Pdp8$react).createElement((0, $7Pdp8$FocusScope), null, /*#__PURE__*/ (0, $7Pdp8$react).createElement($e46feef4e4c28a4b$export$9194c0aa0cd7a9ff.Provider, {
|
|
47
47
|
value: isFocusVisible
|
|
48
48
|
}, /*#__PURE__*/ (0, $7Pdp8$react).createElement("div", {
|
|
49
49
|
...(0, $7Pdp8$mergeProps)(regionProps, focusProps),
|
|
50
50
|
ref: ref,
|
|
51
51
|
"data-position": "bottom",
|
|
52
52
|
"data-placement": "center",
|
|
53
|
-
className: (0, $7Pdp8$classNames)((0, ($parcel$interopDefault($7Pdp8$toastContainer_cssmodulejs))),
|
|
54
|
-
|
|
53
|
+
className: (0, $7Pdp8$classNames)((0, ($parcel$interopDefault($7Pdp8$toastContainer_cssmodulejs))), 'react-spectrum-ToastContainer', {
|
|
54
|
+
'focus-ring': isFocusVisible
|
|
55
|
+
})
|
|
56
|
+
}, children))));
|
|
55
57
|
var _getContainer;
|
|
56
58
|
return /*#__PURE__*/ (0, $7Pdp8$reactdom).createPortal(contents, (_getContainer = getContainer === null || getContainer === void 0 ? void 0 : getContainer()) !== null && _getContainer !== void 0 ? _getContainer : document.body);
|
|
57
59
|
}
|
|
58
60
|
|
|
59
61
|
|
|
60
62
|
export {$e46feef4e4c28a4b$export$9194c0aa0cd7a9ff as ToasterContext, $e46feef4e4c28a4b$export$fb98e3a2a4cd92d7 as Toaster};
|
|
61
|
-
//# sourceMappingURL=Toaster.
|
|
63
|
+
//# sourceMappingURL=Toaster.module.js.map
|
package/dist/Toaster.module.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "./toastContainer.
|
|
1
|
+
import "./toastContainer.da404f80.css";
|
|
2
2
|
import $7Pdp8$toastContainer_cssmodulejs from "./toastContainer_css.module.js";
|
|
3
3
|
import {useToastRegion as $7Pdp8$useToastRegion} from "@react-aria/toast";
|
|
4
4
|
import {classNames as $7Pdp8$classNames} from "@react-spectrum/utils";
|
|
5
|
+
import {useFocusRing as $7Pdp8$useFocusRing, FocusScope as $7Pdp8$FocusScope} from "@react-aria/focus";
|
|
5
6
|
import {mergeProps as $7Pdp8$mergeProps} from "@react-aria/utils";
|
|
6
7
|
import {Provider as $7Pdp8$Provider} from "@react-spectrum/provider";
|
|
7
8
|
import $7Pdp8$react, {createContext as $7Pdp8$createContext, useRef as $7Pdp8$useRef} from "react";
|
|
8
9
|
import $7Pdp8$reactdom from "react-dom";
|
|
9
|
-
import {useFocusRing as $7Pdp8$useFocusRing} from "@react-aria/focus";
|
|
10
10
|
import {useUNSTABLE_PortalContext as $7Pdp8$useUNSTABLE_PortalContext} from "@react-aria/overlays";
|
|
11
11
|
|
|
12
12
|
|
|
@@ -35,23 +35,25 @@ function $parcel$interopDefault(a) {
|
|
|
35
35
|
const $e46feef4e4c28a4b$export$9194c0aa0cd7a9ff = /*#__PURE__*/ (0, $7Pdp8$createContext)(false);
|
|
36
36
|
function $e46feef4e4c28a4b$export$fb98e3a2a4cd92d7(props) {
|
|
37
37
|
let { children: children, state: state } = props;
|
|
38
|
-
let ref = (0, $7Pdp8$useRef)();
|
|
38
|
+
let ref = (0, $7Pdp8$useRef)(undefined);
|
|
39
39
|
let { regionProps: regionProps } = (0, $7Pdp8$useToastRegion)(props, state, ref);
|
|
40
40
|
let { focusProps: focusProps, isFocusVisible: isFocusVisible } = (0, $7Pdp8$useFocusRing)();
|
|
41
41
|
let { getContainer: getContainer } = (0, $7Pdp8$useUNSTABLE_PortalContext)();
|
|
42
42
|
let contents = /*#__PURE__*/ (0, $7Pdp8$react).createElement((0, $7Pdp8$Provider), {
|
|
43
43
|
UNSAFE_style: {
|
|
44
|
-
background:
|
|
44
|
+
background: 'transparent'
|
|
45
45
|
}
|
|
46
|
-
}, /*#__PURE__*/ (0, $7Pdp8$react).createElement($e46feef4e4c28a4b$export$9194c0aa0cd7a9ff.Provider, {
|
|
46
|
+
}, /*#__PURE__*/ (0, $7Pdp8$react).createElement((0, $7Pdp8$FocusScope), null, /*#__PURE__*/ (0, $7Pdp8$react).createElement($e46feef4e4c28a4b$export$9194c0aa0cd7a9ff.Provider, {
|
|
47
47
|
value: isFocusVisible
|
|
48
48
|
}, /*#__PURE__*/ (0, $7Pdp8$react).createElement("div", {
|
|
49
49
|
...(0, $7Pdp8$mergeProps)(regionProps, focusProps),
|
|
50
50
|
ref: ref,
|
|
51
51
|
"data-position": "bottom",
|
|
52
52
|
"data-placement": "center",
|
|
53
|
-
className: (0, $7Pdp8$classNames)((0, ($parcel$interopDefault($7Pdp8$toastContainer_cssmodulejs))),
|
|
54
|
-
|
|
53
|
+
className: (0, $7Pdp8$classNames)((0, ($parcel$interopDefault($7Pdp8$toastContainer_cssmodulejs))), 'react-spectrum-ToastContainer', {
|
|
54
|
+
'focus-ring': isFocusVisible
|
|
55
|
+
})
|
|
56
|
+
}, children))));
|
|
55
57
|
var _getContainer;
|
|
56
58
|
return /*#__PURE__*/ (0, $7Pdp8$reactdom).createPortal(contents, (_getContainer = getContainer === null || getContainer === void 0 ? void 0 : getContainer()) !== null && _getContainer !== void 0 ? _getContainer : document.body);
|
|
57
59
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;AAkBM,MAAM,0DAAiB,CAAA,GAAA,oBAAY,EAAE;AAErC,SAAS,0CAAQ,KAA0B;IAChD,IAAI,YACF,QAAQ,SACR,KAAK,EACN,GAAG;IAEJ,IAAI,MAAM,CAAA,GAAA,aAAK;
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;;;AAkBM,MAAM,0DAAiB,CAAA,GAAA,oBAAY,EAAE;AAErC,SAAS,0CAAQ,KAA0B;IAChD,IAAI,YACF,QAAQ,SACR,KAAK,EACN,GAAG;IAEJ,IAAI,MAAM,CAAA,GAAA,aAAK,EAAE;IACjB,IAAI,eAAC,WAAW,EAAC,GAAG,CAAA,GAAA,qBAAa,EAAE,OAAO,OAAO;IACjD,IAAI,cAAC,UAAU,kBAAE,cAAc,EAAC,GAAG,CAAA,GAAA,mBAAW;IAC9C,IAAI,gBAAC,YAAY,EAAC,GAAG,CAAA,GAAA,gCAAwB;IAE7C,IAAI,yBACF,gCAAC,CAAA,GAAA,eAAO;QAAE,cAAc;YAAC,YAAY;QAAa;qBAChD,gCAAC,CAAA,GAAA,iBAAS,uBACR,gCAAC,0CAAe,QAAQ;QAAC,OAAO;qBAC9B,gCAAC;QACE,GAAG,CAAA,GAAA,iBAAS,EAAE,aAAa,WAAW;QACvC,KAAK;QACL,iBAAc;QACd,kBAAe;QACf,WAAW,CAAA,GAAA,iBAAS,EAClB,CAAA,GAAA,2DAAmB,GACnB,iCACA;YAAC,cAAc;QAAc;OAE9B;QAO4B;IAAvC,qBAAO,CAAA,GAAA,eAAO,EAAE,YAAY,CAAC,UAAU,CAAA,gBAAA,yBAAA,mCAAA,4BAAA,2BAAA,gBAAoB,SAAS,IAAI;AAC1E","sources":["packages/@react-spectrum/toast/src/Toaster.tsx"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {AriaToastRegionProps, useToastRegion} from '@react-aria/toast';\nimport {classNames} from '@react-spectrum/utils';\nimport {FocusScope, useFocusRing} from '@react-aria/focus';\nimport {mergeProps} from '@react-aria/utils';\nimport {Provider} from '@react-spectrum/provider';\nimport React, {createContext, ReactElement, ReactNode, useRef} from 'react';\nimport ReactDOM from 'react-dom';\nimport toastContainerStyles from './toastContainer.css';\nimport {ToastState} from '@react-stately/toast';\nimport {useUNSTABLE_PortalContext} from '@react-aria/overlays';\n\ninterface ToastContainerProps extends AriaToastRegionProps {\n children: ReactNode,\n state: ToastState<unknown>\n}\n\nexport const ToasterContext = createContext(false);\n\nexport function Toaster(props: ToastContainerProps): ReactElement {\n let {\n children,\n state\n } = props;\n\n let ref = useRef(undefined);\n let {regionProps} = useToastRegion(props, state, ref);\n let {focusProps, isFocusVisible} = useFocusRing();\n let {getContainer} = useUNSTABLE_PortalContext();\n\n let contents = (\n <Provider UNSAFE_style={{background: 'transparent'}}>\n <FocusScope>\n <ToasterContext.Provider value={isFocusVisible}>\n <div\n {...mergeProps(regionProps, focusProps)}\n ref={ref}\n data-position=\"bottom\"\n data-placement=\"center\"\n className={classNames(\n toastContainerStyles,\n 'react-spectrum-ToastContainer',\n {'focus-ring': isFocusVisible}\n )}>\n {children}\n </div>\n </ToasterContext.Provider>\n </FocusScope>\n </Provider>\n );\n\n return ReactDOM.createPortal(contents, getContainer?.() ?? document.body);\n}\n"],"names":[],"version":3,"file":"Toaster.module.js.map"}
|
package/dist/ar-AE.mjs
CHANGED
package/dist/bg-BG.mjs
CHANGED
package/dist/cs-CZ.mjs
CHANGED
package/dist/da-DK.mjs
CHANGED
package/dist/de-DE.mjs
CHANGED
package/dist/el-GR.mjs
CHANGED
package/dist/en-US.mjs
CHANGED
package/dist/es-ES.mjs
CHANGED
package/dist/et-EE.mjs
CHANGED
package/dist/fi-FI.mjs
CHANGED
package/dist/fr-FR.mjs
CHANGED
package/dist/he-IL.mjs
CHANGED
package/dist/hr-HR.mjs
CHANGED
package/dist/hu-HU.mjs
CHANGED
package/dist/intlStrings.mjs
CHANGED
package/dist/it-IT.mjs
CHANGED
package/dist/ja-JP.mjs
CHANGED
package/dist/ko-KR.mjs
CHANGED
package/dist/lt-LT.mjs
CHANGED
package/dist/lv-LV.mjs
CHANGED
package/dist/nb-NO.mjs
CHANGED
package/dist/nl-NL.mjs
CHANGED
package/dist/pl-PL.mjs
CHANGED
package/dist/pt-BR.mjs
CHANGED
package/dist/pt-PT.mjs
CHANGED
package/dist/ro-RO.mjs
CHANGED
package/dist/ru-RU.mjs
CHANGED
package/dist/sk-SK.mjs
CHANGED
package/dist/sl-SI.mjs
CHANGED
package/dist/sr-SP.mjs
CHANGED
package/dist/sv-SE.mjs
CHANGED
|
@@ -42,10 +42,14 @@
|
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
.xynrca_react-spectrum-ToastContainer {
|
|
45
|
+
--spectrum-focus-ring-border-radius: var(--spectrum-toast-border-radius, var(--spectrum-global-dimension-static-size-50));
|
|
46
|
+
--spectrum-focus-ring-gap: var(--spectrum-alias-focus-ring-gap, var(--spectrum-global-dimension-static-size-25));
|
|
47
|
+
--spectrum-focus-ring-size: var(--spectrum-alias-focus-ring-size, var(--spectrum-global-dimension-static-size-25));
|
|
45
48
|
z-index: 100050;
|
|
46
49
|
pointer-events: none;
|
|
47
50
|
outline: none;
|
|
48
51
|
margin-block-end: 8px;
|
|
52
|
+
margin-inline: 8px;
|
|
49
53
|
display: flex;
|
|
50
54
|
position: fixed;
|
|
51
55
|
left: 0;
|
|
@@ -60,14 +64,14 @@
|
|
|
60
64
|
.xynrca_react-spectrum-ToastContainer[data-position="top"] {
|
|
61
65
|
--slide-from: translateY(-100%);
|
|
62
66
|
--slide-to: translateY(0);
|
|
63
|
-
flex-direction: column
|
|
67
|
+
flex-direction: column;
|
|
64
68
|
top: 0;
|
|
65
69
|
}
|
|
66
70
|
|
|
67
71
|
.xynrca_react-spectrum-ToastContainer[data-position="bottom"] {
|
|
68
72
|
--slide-from: translateY(100%);
|
|
69
73
|
--slide-to: translateY(0);
|
|
70
|
-
flex-direction: column;
|
|
74
|
+
flex-direction: column-reverse;
|
|
71
75
|
bottom: 0;
|
|
72
76
|
}
|
|
73
77
|
|
|
@@ -107,6 +111,8 @@
|
|
|
107
111
|
--spectrum-focus-ring-border-radius: var(--spectrum-toast-border-radius, var(--spectrum-global-dimension-static-size-50));
|
|
108
112
|
--spectrum-focus-ring-gap: var(--spectrum-alias-focus-ring-gap, var(--spectrum-global-dimension-static-size-25));
|
|
109
113
|
--spectrum-focus-ring-size: var(--spectrum-alias-focus-ring-size, var(--spectrum-global-dimension-static-size-25));
|
|
114
|
+
outline: none;
|
|
115
|
+
position: relative;
|
|
110
116
|
}
|
|
111
117
|
|
|
112
118
|
.xynrca_spectrum-Toast[data-animation="entering"] {
|
|
@@ -117,6 +123,24 @@
|
|
|
117
123
|
animation: .3s forwards xynrca_fade-out;
|
|
118
124
|
}
|
|
119
125
|
|
|
126
|
+
.xynrca_spectrum-Toast .xynrca_spectrum-Toast-contentWrapper {
|
|
127
|
+
display: inline-flex;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.xynrca_spectrum-ToastContainer-list {
|
|
131
|
+
display: inherit;
|
|
132
|
+
flex-direction: inherit;
|
|
133
|
+
align-items: inherit;
|
|
134
|
+
margin-block: 0;
|
|
135
|
+
margin-inline: 0;
|
|
136
|
+
padding-inline-start: 0;
|
|
137
|
+
list-style-type: none;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.xynrca_spectrum-ToastContainer-listitem {
|
|
141
|
+
display: inline-block;
|
|
142
|
+
}
|
|
143
|
+
|
|
120
144
|
@keyframes xynrca_slide-in {
|
|
121
145
|
from {
|
|
122
146
|
transform: var(--slide-from);
|
|
@@ -136,4 +160,4 @@
|
|
|
136
160
|
opacity: 0;
|
|
137
161
|
}
|
|
138
162
|
}
|
|
139
|
-
/*# sourceMappingURL=toastContainer.
|
|
163
|
+
/*# sourceMappingURL=toastContainer.da404f80.css.map */
|