react-aria-components 1.11.0 → 1.12.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/dist/Autocomplete.main.js +7 -20
- package/dist/Autocomplete.main.js.map +1 -1
- package/dist/Autocomplete.mjs +8 -20
- package/dist/Autocomplete.module.js +8 -20
- package/dist/Autocomplete.module.js.map +1 -1
- package/dist/Breadcrumbs.main.js +4 -1
- package/dist/Breadcrumbs.main.js.map +1 -1
- package/dist/Breadcrumbs.mjs +5 -2
- package/dist/Breadcrumbs.module.js +5 -2
- package/dist/Breadcrumbs.module.js.map +1 -1
- package/dist/GridList.main.js +96 -15
- package/dist/GridList.main.js.map +1 -1
- package/dist/GridList.mjs +98 -19
- package/dist/GridList.module.js +98 -19
- package/dist/GridList.module.js.map +1 -1
- package/dist/Header.main.js +1 -1
- package/dist/Header.main.js.map +1 -1
- package/dist/Header.mjs +2 -2
- package/dist/Header.module.js +2 -2
- package/dist/Header.module.js.map +1 -1
- package/dist/ListBox.main.js +6 -18
- package/dist/ListBox.main.js.map +1 -1
- package/dist/ListBox.mjs +8 -20
- package/dist/ListBox.module.js +8 -20
- package/dist/ListBox.module.js.map +1 -1
- package/dist/Menu.main.js +29 -15
- package/dist/Menu.main.js.map +1 -1
- package/dist/Menu.mjs +31 -17
- package/dist/Menu.module.js +31 -17
- package/dist/Menu.module.js.map +1 -1
- package/dist/Popover.main.js +7 -11
- package/dist/Popover.main.js.map +1 -1
- package/dist/Popover.mjs +8 -12
- package/dist/Popover.module.js +8 -12
- package/dist/Popover.module.js.map +1 -1
- package/dist/SearchField.main.js +6 -4
- package/dist/SearchField.main.js.map +1 -1
- package/dist/SearchField.mjs +7 -5
- package/dist/SearchField.module.js +7 -5
- package/dist/SearchField.module.js.map +1 -1
- package/dist/Separator.main.js +13 -1
- package/dist/Separator.main.js.map +1 -1
- package/dist/Separator.mjs +15 -3
- package/dist/Separator.module.js +15 -3
- package/dist/Separator.module.js.map +1 -1
- package/dist/Table.main.js +58 -17
- package/dist/Table.main.js.map +1 -1
- package/dist/Table.mjs +60 -19
- package/dist/Table.module.js +60 -19
- package/dist/Table.module.js.map +1 -1
- package/dist/Tabs.main.js +4 -1
- package/dist/Tabs.main.js.map +1 -1
- package/dist/Tabs.mjs +5 -2
- package/dist/Tabs.module.js +5 -2
- package/dist/Tabs.module.js.map +1 -1
- package/dist/TagGroup.main.js +13 -4
- package/dist/TagGroup.main.js.map +1 -1
- package/dist/TagGroup.mjs +15 -6
- package/dist/TagGroup.module.js +15 -6
- package/dist/TagGroup.module.js.map +1 -1
- package/dist/TextField.main.js +7 -5
- package/dist/TextField.main.js.map +1 -1
- package/dist/TextField.mjs +8 -6
- package/dist/TextField.module.js +8 -6
- package/dist/TextField.module.js.map +1 -1
- package/dist/Tooltip.main.js +4 -11
- package/dist/Tooltip.main.js.map +1 -1
- package/dist/Tooltip.mjs +6 -13
- package/dist/Tooltip.module.js +6 -13
- package/dist/Tooltip.module.js.map +1 -1
- package/dist/Tree.main.js +9 -3
- package/dist/Tree.main.js.map +1 -1
- package/dist/Tree.mjs +10 -4
- package/dist/Tree.module.js +10 -4
- package/dist/Tree.module.js.map +1 -1
- package/dist/context.main.js +25 -0
- package/dist/context.main.js.map +1 -0
- package/dist/context.mjs +19 -0
- package/dist/context.module.js +19 -0
- package/dist/context.module.js.map +1 -0
- package/dist/import.mjs +3 -3
- package/dist/main.js +3 -0
- package/dist/main.js.map +1 -1
- package/dist/module.js +3 -3
- package/dist/module.js.map +1 -1
- package/dist/types.d.ts +178 -171
- package/dist/types.d.ts.map +1 -1
- package/dist/useDragAndDrop.main.js.map +1 -1
- package/dist/useDragAndDrop.module.js.map +1 -1
- package/package.json +23 -22
- package/src/Autocomplete.tsx +14 -25
- package/src/Breadcrumbs.tsx +6 -2
- package/src/GridList.tsx +89 -21
- package/src/Header.tsx +2 -2
- package/src/ListBox.tsx +12 -15
- package/src/Menu.tsx +37 -17
- package/src/Popover.tsx +11 -11
- package/src/SearchField.tsx +5 -4
- package/src/Separator.tsx +17 -2
- package/src/Table.tsx +65 -22
- package/src/Tabs.tsx +6 -2
- package/src/TagGroup.tsx +15 -6
- package/src/TextField.tsx +8 -7
- package/src/Tooltip.tsx +10 -14
- package/src/Tree.tsx +13 -5
- package/src/context.tsx +34 -0
- package/src/index.ts +2 -2
- package/src/useDragAndDrop.tsx +9 -9
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
var $
|
|
1
|
+
var $09cb5ee89bb327e1$exports = require("./context.main.js");
|
|
2
2
|
var $c5ccf687772c0422$exports = require("./utils.main.js");
|
|
3
|
-
var $a83c69b310385d53$exports = require("./SearchField.main.js");
|
|
4
|
-
var $3f2c5af9d7d8905b$exports = require("./TextField.main.js");
|
|
5
3
|
var $5lGAV$reactariaautocomplete = require("@react-aria/autocomplete");
|
|
6
4
|
var $5lGAV$reactstatelyautocomplete = require("@react-stately/autocomplete");
|
|
7
5
|
var $5lGAV$reactariautils = require("@react-aria/utils");
|
|
@@ -18,7 +16,6 @@ function $parcel$export(e, n, v, s) {
|
|
|
18
16
|
|
|
19
17
|
$parcel$export(module.exports, "AutocompleteContext", () => $33f48720060787fa$export$36e687af51cd0967);
|
|
20
18
|
$parcel$export(module.exports, "AutocompleteStateContext", () => $33f48720060787fa$export$68ee3368b6d68148);
|
|
21
|
-
$parcel$export(module.exports, "UNSTABLE_InternalAutocompleteContext", () => $33f48720060787fa$export$65d2a03b8800d6e3);
|
|
22
19
|
$parcel$export(module.exports, "Autocomplete", () => $33f48720060787fa$export$2f2b9559550c7bbc);
|
|
23
20
|
/*
|
|
24
21
|
* Copyright 2024 Adobe. All rights reserved.
|
|
@@ -36,11 +33,8 @@ $parcel$export(module.exports, "Autocomplete", () => $33f48720060787fa$export$2f
|
|
|
36
33
|
|
|
37
34
|
|
|
38
35
|
|
|
39
|
-
|
|
40
|
-
|
|
41
36
|
const $33f48720060787fa$export$36e687af51cd0967 = /*#__PURE__*/ (0, $5lGAV$react.createContext)(null);
|
|
42
37
|
const $33f48720060787fa$export$68ee3368b6d68148 = /*#__PURE__*/ (0, $5lGAV$react.createContext)(null);
|
|
43
|
-
const $33f48720060787fa$export$65d2a03b8800d6e3 = /*#__PURE__*/ (0, $5lGAV$react.createContext)(null);
|
|
44
38
|
function $33f48720060787fa$export$2f2b9559550c7bbc(props) {
|
|
45
39
|
let ctx = (0, $c5ccf687772c0422$exports.useSlottedContext)($33f48720060787fa$export$36e687af51cd0967, props.slot);
|
|
46
40
|
props = (0, $5lGAV$reactariautils.mergeProps)(ctx, props);
|
|
@@ -48,7 +42,7 @@ function $33f48720060787fa$export$2f2b9559550c7bbc(props) {
|
|
|
48
42
|
let state = (0, $5lGAV$reactstatelyautocomplete.useAutocompleteState)(props);
|
|
49
43
|
let inputRef = (0, $5lGAV$react.useRef)(null);
|
|
50
44
|
let collectionRef = (0, $5lGAV$react.useRef)(null);
|
|
51
|
-
let {
|
|
45
|
+
let { inputProps: inputProps, collectionProps: collectionProps, collectionRef: mergedCollectionRef, filter: filterFn } = (0, $5lGAV$reactariaautocomplete.useAutocomplete)({
|
|
52
46
|
...(0, $c5ccf687772c0422$exports.removeDataAttributes)(props),
|
|
53
47
|
filter: filter,
|
|
54
48
|
disableAutoFocusFirst: disableAutoFocusFirst,
|
|
@@ -62,25 +56,18 @@ function $33f48720060787fa$export$2f2b9559550c7bbc(props) {
|
|
|
62
56
|
state
|
|
63
57
|
],
|
|
64
58
|
[
|
|
65
|
-
(0, $
|
|
66
|
-
textFieldProps
|
|
67
|
-
],
|
|
68
|
-
[
|
|
69
|
-
(0, $3f2c5af9d7d8905b$exports.TextFieldContext),
|
|
70
|
-
textFieldProps
|
|
71
|
-
],
|
|
72
|
-
[
|
|
73
|
-
(0, $1bcfcef5af644e13$exports.InputContext),
|
|
59
|
+
(0, $09cb5ee89bb327e1$exports.FieldInputContext),
|
|
74
60
|
{
|
|
61
|
+
...inputProps,
|
|
75
62
|
ref: inputRef
|
|
76
63
|
}
|
|
77
64
|
],
|
|
78
65
|
[
|
|
79
|
-
$
|
|
66
|
+
(0, $09cb5ee89bb327e1$exports.SelectableCollectionContext),
|
|
80
67
|
{
|
|
68
|
+
...collectionProps,
|
|
81
69
|
filter: filterFn,
|
|
82
|
-
|
|
83
|
-
collectionRef: mergedCollectionRef
|
|
70
|
+
ref: mergedCollectionRef
|
|
84
71
|
}
|
|
85
72
|
]
|
|
86
73
|
]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAUM,MAAM,0DAAsB,CAAA,GAAA,0BAAY,EAAwD;AAChG,MAAM,0DAA2B,CAAA,GAAA,0BAAY,EAA4B;AAKzE,SAAS,0CAA+B,KAA2B;IACxE,IAAI,MAAM,CAAA,GAAA,2CAAgB,EAAE,2CAAqB,MAAM,IAAI;IAC3D,QAAQ,CAAA,GAAA,gCAAS,EAAE,KAAK;IACxB,IAAI,UAAC,MAAM,yBAAE,qBAAqB,EAAC,GAAG;IACtC,IAAI,QAAQ,CAAA,GAAA,oDAAmB,EAAE;IACjC,IAAI,WAAW,CAAA,GAAA,mBAAK,EAA2B;IAC/C,IAAI,gBAAgB,CAAA,GAAA,mBAAK,EAAe;IACxC,IAAI,cACF,UAAU,mBACV,eAAe,EACf,eAAe,mBAAmB,EAClC,QAAQ,QAAQ,EACjB,GAAG,CAAA,GAAA,4CAAc,EAAE;QAClB,GAAG,CAAA,GAAA,8CAAmB,EAAE,MAAM;gBAC9B;+BACA;kBACA;uBACA;IACF,GAAG;IAEH,qBACE,0DAAC,CAAA,GAAA,kCAAO;QACN,QAAQ;YACN;gBAAC;gBAA0B;aAAM;YACjC;gBAAC,CAAA,GAAA,2CAAgB;gBAAG;oBAClB,GAAG,UAAU;oBACb,KAAK;gBACP;aAAE;YACF;gBAAC,CAAA,GAAA,qDAA0B;gBAAG;oBAC5B,GAAG,eAAe;oBAClB,QAAQ;oBACR,KAAK;gBACP;aAAE;SACH;OACA,MAAM,QAAQ;AAGrB","sources":["packages/react-aria-components/src/Autocomplete.tsx"],"sourcesContent":["/*\n * Copyright 2024 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 {AriaAutocompleteProps, useAutocomplete} from '@react-aria/autocomplete';\nimport {AutocompleteState, useAutocompleteState} from '@react-stately/autocomplete';\nimport {FieldInputContext, SelectableCollectionContext} from './context';\nimport {mergeProps} from '@react-aria/utils';\nimport {Provider, removeDataAttributes, SlotProps, SlottedContextValue, useSlottedContext} from './utils';\nimport React, {createContext, JSX, useRef} from 'react';\n\nexport interface AutocompleteProps<T = object> extends AriaAutocompleteProps<T>, SlotProps {}\nexport const AutocompleteContext = createContext<SlottedContextValue<Partial<AutocompleteProps<any>>>>(null);\nexport const AutocompleteStateContext = createContext<AutocompleteState | null>(null);\n\n/**\n * An autocomplete combines a TextField or SearchField with a Menu or ListBox, allowing users to search or filter a list of suggestions.\n */\nexport function Autocomplete<T extends object>(props: AutocompleteProps<T>): JSX.Element {\n let ctx = useSlottedContext(AutocompleteContext, props.slot);\n props = mergeProps(ctx, props);\n let {filter, disableAutoFocusFirst} = props;\n let state = useAutocompleteState(props);\n let inputRef = useRef<HTMLInputElement | null>(null);\n let collectionRef = useRef<HTMLElement>(null);\n let {\n inputProps,\n collectionProps,\n collectionRef: mergedCollectionRef,\n filter: filterFn\n } = useAutocomplete({\n ...removeDataAttributes(props),\n filter,\n disableAutoFocusFirst,\n inputRef,\n collectionRef\n }, state);\n\n return (\n <Provider\n values={[\n [AutocompleteStateContext, state],\n [FieldInputContext, {\n ...inputProps,\n ref: inputRef\n }],\n [SelectableCollectionContext, {\n ...collectionProps,\n filter: filterFn,\n ref: mergedCollectionRef\n }]\n ]}>\n {props.children}\n </Provider>\n );\n};\n"],"names":[],"version":3,"file":"Autocomplete.main.js.map"}
|
package/dist/Autocomplete.mjs
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {FieldInputContext as $8e6cc465cc68f603$export$698f465ec27e93df, SelectableCollectionContext as $8e6cc465cc68f603$export$b0d3ecf7112093a7} from "./context.mjs";
|
|
2
2
|
import {Provider as $64fa3d84918910a7$export$2881499e37b75b9a, removeDataAttributes as $64fa3d84918910a7$export$ef03459518577ad4, useSlottedContext as $64fa3d84918910a7$export$fabf2dc03a41866e} from "./utils.mjs";
|
|
3
|
-
import {SearchFieldContext as $440f4836bcb56932$export$d1c4e4c63cb03a11} from "./SearchField.mjs";
|
|
4
|
-
import {TextFieldContext as $bcdf0525bf22703d$export$2129e27b3ef0d483} from "./TextField.mjs";
|
|
5
3
|
import {useAutocomplete as $llkzs$useAutocomplete} from "@react-aria/autocomplete";
|
|
6
4
|
import {useAutocompleteState as $llkzs$useAutocompleteState} from "@react-stately/autocomplete";
|
|
7
5
|
import {mergeProps as $llkzs$mergeProps} from "@react-aria/utils";
|
|
@@ -23,11 +21,8 @@ import $llkzs$react, {createContext as $llkzs$createContext, useRef as $llkzs$us
|
|
|
23
21
|
|
|
24
22
|
|
|
25
23
|
|
|
26
|
-
|
|
27
|
-
|
|
28
24
|
const $d2f53cda644affe3$export$36e687af51cd0967 = /*#__PURE__*/ (0, $llkzs$createContext)(null);
|
|
29
25
|
const $d2f53cda644affe3$export$68ee3368b6d68148 = /*#__PURE__*/ (0, $llkzs$createContext)(null);
|
|
30
|
-
const $d2f53cda644affe3$export$65d2a03b8800d6e3 = /*#__PURE__*/ (0, $llkzs$createContext)(null);
|
|
31
26
|
function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
32
27
|
let ctx = (0, $64fa3d84918910a7$export$fabf2dc03a41866e)($d2f53cda644affe3$export$36e687af51cd0967, props.slot);
|
|
33
28
|
props = (0, $llkzs$mergeProps)(ctx, props);
|
|
@@ -35,7 +30,7 @@ function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
|
35
30
|
let state = (0, $llkzs$useAutocompleteState)(props);
|
|
36
31
|
let inputRef = (0, $llkzs$useRef)(null);
|
|
37
32
|
let collectionRef = (0, $llkzs$useRef)(null);
|
|
38
|
-
let {
|
|
33
|
+
let { inputProps: inputProps, collectionProps: collectionProps, collectionRef: mergedCollectionRef, filter: filterFn } = (0, $llkzs$useAutocomplete)({
|
|
39
34
|
...(0, $64fa3d84918910a7$export$ef03459518577ad4)(props),
|
|
40
35
|
filter: filter,
|
|
41
36
|
disableAutoFocusFirst: disableAutoFocusFirst,
|
|
@@ -49,25 +44,18 @@ function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
|
49
44
|
state
|
|
50
45
|
],
|
|
51
46
|
[
|
|
52
|
-
(0, $
|
|
53
|
-
textFieldProps
|
|
54
|
-
],
|
|
55
|
-
[
|
|
56
|
-
(0, $bcdf0525bf22703d$export$2129e27b3ef0d483),
|
|
57
|
-
textFieldProps
|
|
58
|
-
],
|
|
59
|
-
[
|
|
60
|
-
(0, $3985021b0ad6602f$export$37fb8590cf2c088c),
|
|
47
|
+
(0, $8e6cc465cc68f603$export$698f465ec27e93df),
|
|
61
48
|
{
|
|
49
|
+
...inputProps,
|
|
62
50
|
ref: inputRef
|
|
63
51
|
}
|
|
64
52
|
],
|
|
65
53
|
[
|
|
66
|
-
$
|
|
54
|
+
(0, $8e6cc465cc68f603$export$b0d3ecf7112093a7),
|
|
67
55
|
{
|
|
56
|
+
...collectionProps,
|
|
68
57
|
filter: filterFn,
|
|
69
|
-
|
|
70
|
-
collectionRef: mergedCollectionRef
|
|
58
|
+
ref: mergedCollectionRef
|
|
71
59
|
}
|
|
72
60
|
]
|
|
73
61
|
]
|
|
@@ -75,5 +63,5 @@ function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
|
75
63
|
}
|
|
76
64
|
|
|
77
65
|
|
|
78
|
-
export {$d2f53cda644affe3$export$36e687af51cd0967 as AutocompleteContext, $d2f53cda644affe3$export$68ee3368b6d68148 as AutocompleteStateContext, $d2f53cda644affe3$export$
|
|
66
|
+
export {$d2f53cda644affe3$export$36e687af51cd0967 as AutocompleteContext, $d2f53cda644affe3$export$68ee3368b6d68148 as AutocompleteStateContext, $d2f53cda644affe3$export$2f2b9559550c7bbc as Autocomplete};
|
|
79
67
|
//# sourceMappingURL=Autocomplete.module.js.map
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {FieldInputContext as $8e6cc465cc68f603$export$698f465ec27e93df, SelectableCollectionContext as $8e6cc465cc68f603$export$b0d3ecf7112093a7} from "./context.module.js";
|
|
2
2
|
import {Provider as $64fa3d84918910a7$export$2881499e37b75b9a, removeDataAttributes as $64fa3d84918910a7$export$ef03459518577ad4, useSlottedContext as $64fa3d84918910a7$export$fabf2dc03a41866e} from "./utils.module.js";
|
|
3
|
-
import {SearchFieldContext as $440f4836bcb56932$export$d1c4e4c63cb03a11} from "./SearchField.module.js";
|
|
4
|
-
import {TextFieldContext as $bcdf0525bf22703d$export$2129e27b3ef0d483} from "./TextField.module.js";
|
|
5
3
|
import {useAutocomplete as $llkzs$useAutocomplete} from "@react-aria/autocomplete";
|
|
6
4
|
import {useAutocompleteState as $llkzs$useAutocompleteState} from "@react-stately/autocomplete";
|
|
7
5
|
import {mergeProps as $llkzs$mergeProps} from "@react-aria/utils";
|
|
@@ -23,11 +21,8 @@ import $llkzs$react, {createContext as $llkzs$createContext, useRef as $llkzs$us
|
|
|
23
21
|
|
|
24
22
|
|
|
25
23
|
|
|
26
|
-
|
|
27
|
-
|
|
28
24
|
const $d2f53cda644affe3$export$36e687af51cd0967 = /*#__PURE__*/ (0, $llkzs$createContext)(null);
|
|
29
25
|
const $d2f53cda644affe3$export$68ee3368b6d68148 = /*#__PURE__*/ (0, $llkzs$createContext)(null);
|
|
30
|
-
const $d2f53cda644affe3$export$65d2a03b8800d6e3 = /*#__PURE__*/ (0, $llkzs$createContext)(null);
|
|
31
26
|
function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
32
27
|
let ctx = (0, $64fa3d84918910a7$export$fabf2dc03a41866e)($d2f53cda644affe3$export$36e687af51cd0967, props.slot);
|
|
33
28
|
props = (0, $llkzs$mergeProps)(ctx, props);
|
|
@@ -35,7 +30,7 @@ function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
|
35
30
|
let state = (0, $llkzs$useAutocompleteState)(props);
|
|
36
31
|
let inputRef = (0, $llkzs$useRef)(null);
|
|
37
32
|
let collectionRef = (0, $llkzs$useRef)(null);
|
|
38
|
-
let {
|
|
33
|
+
let { inputProps: inputProps, collectionProps: collectionProps, collectionRef: mergedCollectionRef, filter: filterFn } = (0, $llkzs$useAutocomplete)({
|
|
39
34
|
...(0, $64fa3d84918910a7$export$ef03459518577ad4)(props),
|
|
40
35
|
filter: filter,
|
|
41
36
|
disableAutoFocusFirst: disableAutoFocusFirst,
|
|
@@ -49,25 +44,18 @@ function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
|
49
44
|
state
|
|
50
45
|
],
|
|
51
46
|
[
|
|
52
|
-
(0, $
|
|
53
|
-
textFieldProps
|
|
54
|
-
],
|
|
55
|
-
[
|
|
56
|
-
(0, $bcdf0525bf22703d$export$2129e27b3ef0d483),
|
|
57
|
-
textFieldProps
|
|
58
|
-
],
|
|
59
|
-
[
|
|
60
|
-
(0, $3985021b0ad6602f$export$37fb8590cf2c088c),
|
|
47
|
+
(0, $8e6cc465cc68f603$export$698f465ec27e93df),
|
|
61
48
|
{
|
|
49
|
+
...inputProps,
|
|
62
50
|
ref: inputRef
|
|
63
51
|
}
|
|
64
52
|
],
|
|
65
53
|
[
|
|
66
|
-
$
|
|
54
|
+
(0, $8e6cc465cc68f603$export$b0d3ecf7112093a7),
|
|
67
55
|
{
|
|
56
|
+
...collectionProps,
|
|
68
57
|
filter: filterFn,
|
|
69
|
-
|
|
70
|
-
collectionRef: mergedCollectionRef
|
|
58
|
+
ref: mergedCollectionRef
|
|
71
59
|
}
|
|
72
60
|
]
|
|
73
61
|
]
|
|
@@ -75,5 +63,5 @@ function $d2f53cda644affe3$export$2f2b9559550c7bbc(props) {
|
|
|
75
63
|
}
|
|
76
64
|
|
|
77
65
|
|
|
78
|
-
export {$d2f53cda644affe3$export$36e687af51cd0967 as AutocompleteContext, $d2f53cda644affe3$export$68ee3368b6d68148 as AutocompleteStateContext, $d2f53cda644affe3$export$
|
|
66
|
+
export {$d2f53cda644affe3$export$36e687af51cd0967 as AutocompleteContext, $d2f53cda644affe3$export$68ee3368b6d68148 as AutocompleteStateContext, $d2f53cda644affe3$export$2f2b9559550c7bbc as Autocomplete};
|
|
79
67
|
//# sourceMappingURL=Autocomplete.module.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;AAUM,MAAM,0DAAsB,CAAA,GAAA,oBAAY,EAAwD;AAChG,MAAM,0DAA2B,CAAA,GAAA,oBAAY,EAA4B;AAKzE,SAAS,0CAA+B,KAA2B;IACxE,IAAI,MAAM,CAAA,GAAA,yCAAgB,EAAE,2CAAqB,MAAM,IAAI;IAC3D,QAAQ,CAAA,GAAA,iBAAS,EAAE,KAAK;IACxB,IAAI,UAAC,MAAM,yBAAE,qBAAqB,EAAC,GAAG;IACtC,IAAI,QAAQ,CAAA,GAAA,2BAAmB,EAAE;IACjC,IAAI,WAAW,CAAA,GAAA,aAAK,EAA2B;IAC/C,IAAI,gBAAgB,CAAA,GAAA,aAAK,EAAe;IACxC,IAAI,cACF,UAAU,mBACV,eAAe,EACf,eAAe,mBAAmB,EAClC,QAAQ,QAAQ,EACjB,GAAG,CAAA,GAAA,sBAAc,EAAE;QAClB,GAAG,CAAA,GAAA,yCAAmB,EAAE,MAAM;gBAC9B;+BACA;kBACA;uBACA;IACF,GAAG;IAEH,qBACE,gCAAC,CAAA,GAAA,yCAAO;QACN,QAAQ;YACN;gBAAC;gBAA0B;aAAM;YACjC;gBAAC,CAAA,GAAA,yCAAgB;gBAAG;oBAClB,GAAG,UAAU;oBACb,KAAK;gBACP;aAAE;YACF;gBAAC,CAAA,GAAA,yCAA0B;gBAAG;oBAC5B,GAAG,eAAe;oBAClB,QAAQ;oBACR,KAAK;gBACP;aAAE;SACH;OACA,MAAM,QAAQ;AAGrB","sources":["packages/react-aria-components/src/Autocomplete.tsx"],"sourcesContent":["/*\n * Copyright 2024 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 {AriaAutocompleteProps, useAutocomplete} from '@react-aria/autocomplete';\nimport {AutocompleteState, useAutocompleteState} from '@react-stately/autocomplete';\nimport {FieldInputContext, SelectableCollectionContext} from './context';\nimport {mergeProps} from '@react-aria/utils';\nimport {Provider, removeDataAttributes, SlotProps, SlottedContextValue, useSlottedContext} from './utils';\nimport React, {createContext, JSX, useRef} from 'react';\n\nexport interface AutocompleteProps<T = object> extends AriaAutocompleteProps<T>, SlotProps {}\nexport const AutocompleteContext = createContext<SlottedContextValue<Partial<AutocompleteProps<any>>>>(null);\nexport const AutocompleteStateContext = createContext<AutocompleteState | null>(null);\n\n/**\n * An autocomplete combines a TextField or SearchField with a Menu or ListBox, allowing users to search or filter a list of suggestions.\n */\nexport function Autocomplete<T extends object>(props: AutocompleteProps<T>): JSX.Element {\n let ctx = useSlottedContext(AutocompleteContext, props.slot);\n props = mergeProps(ctx, props);\n let {filter, disableAutoFocusFirst} = props;\n let state = useAutocompleteState(props);\n let inputRef = useRef<HTMLInputElement | null>(null);\n let collectionRef = useRef<HTMLElement>(null);\n let {\n inputProps,\n collectionProps,\n collectionRef: mergedCollectionRef,\n filter: filterFn\n } = useAutocomplete({\n ...removeDataAttributes(props),\n filter,\n disableAutoFocusFirst,\n inputRef,\n collectionRef\n }, state);\n\n return (\n <Provider\n values={[\n [AutocompleteStateContext, state],\n [FieldInputContext, {\n ...inputProps,\n ref: inputRef\n }],\n [SelectableCollectionContext, {\n ...collectionProps,\n filter: filterFn,\n ref: mergedCollectionRef\n }]\n ]}>\n {props.children}\n </Provider>\n );\n};\n"],"names":[],"version":3,"file":"Autocomplete.module.js.map"}
|
package/dist/Breadcrumbs.main.js
CHANGED
|
@@ -60,7 +60,10 @@ const $afa44b644f65ed30$export$2dc68d50d56fbbd = /*#__PURE__*/ (0, $l7mU3$react.
|
|
|
60
60
|
})));
|
|
61
61
|
});
|
|
62
62
|
});
|
|
63
|
-
|
|
63
|
+
class $afa44b644f65ed30$var$BreadcrumbNode extends (0, $l7mU3$reactariacollections.CollectionNode) {
|
|
64
|
+
}
|
|
65
|
+
$afa44b644f65ed30$var$BreadcrumbNode.type = 'item';
|
|
66
|
+
const $afa44b644f65ed30$export$dabcc1ec9dd9d1cc = /*#__PURE__*/ (0, $l7mU3$reactariacollections.createLeafComponent)($afa44b644f65ed30$var$BreadcrumbNode, function Breadcrumb(props, ref, node) {
|
|
64
67
|
// Recreating useBreadcrumbItem because we want to use composition instead of having the link builtin.
|
|
65
68
|
let isCurrent = node.nextKey == null;
|
|
66
69
|
let { isDisabled: isDisabled, onAction: onAction } = (0, $c5ccf687772c0422$exports.useSlottedContext)($afa44b644f65ed30$export$65596d3621b0a4a0);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAkBM,MAAM,0DAAqB,CAAA,GAAA,0BAAY,EAAyD;AAKhG,MAAM,2CAA4B,AAAd,WAAW,GAAI,CAAA,GAAA,uBAAS,EAAqB,SAAS,YAA8B,KAA0B,EAAE,GAAmC;IAC5K,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,kBAAC,cAAc,EAAC,GAAG,CAAA,GAAA,uBAAS,EAAE,CAAA,GAAA,mDAAwB;IAC1D,IAAI,YAAC,QAAQ,EAAC,GAAG,CAAA,GAAA,+BAAa,EAAE;IAChC,IAAI,WAAW,CAAA,GAAA,oCAAa,EAAE,OAAO;QAAC,QAAQ;IAAI;IAElD,qBACE,0DAAC,CAAA,GAAA,6CAAgB;QAAE,uBAAS,0DAAC,CAAA,GAAA,sCAAS,GAAM;OACzC,CAAA;YAMc;6BALb,0DAAC;YACC,KAAK;YACJ,GAAG,CAAA,GAAA,gCAAS,EAAE,UAAU,SAAS;YAClC,MAAM,MAAM,IAAI,IAAI;YACpB,OAAO,MAAM,KAAK;YAClB,WAAW,CAAA,mBAAA,MAAM,SAAS,cAAf,8BAAA,mBAAmB;yBAC9B,0DAAC,0CAAmB,QAAQ;YAAC,OAAO;yBAClC,0DAAC;YAAe,YAAY;;;AAMxC;
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAkBM,MAAM,0DAAqB,CAAA,GAAA,0BAAY,EAAyD;AAKhG,MAAM,2CAA4B,AAAd,WAAW,GAAI,CAAA,GAAA,uBAAS,EAAqB,SAAS,YAA8B,KAA0B,EAAE,GAAmC;IAC5K,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,kBAAC,cAAc,EAAC,GAAG,CAAA,GAAA,uBAAS,EAAE,CAAA,GAAA,mDAAwB;IAC1D,IAAI,YAAC,QAAQ,EAAC,GAAG,CAAA,GAAA,+BAAa,EAAE;IAChC,IAAI,WAAW,CAAA,GAAA,oCAAa,EAAE,OAAO;QAAC,QAAQ;IAAI;IAElD,qBACE,0DAAC,CAAA,GAAA,6CAAgB;QAAE,uBAAS,0DAAC,CAAA,GAAA,sCAAS,GAAM;OACzC,CAAA;YAMc;6BALb,0DAAC;YACC,KAAK;YACJ,GAAG,CAAA,GAAA,gCAAS,EAAE,UAAU,SAAS;YAClC,MAAM,MAAM,IAAI,IAAI;YACpB,OAAO,MAAM,KAAK;YAClB,WAAW,CAAA,mBAAA,MAAM,SAAS,cAAf,8BAAA,mBAAmB;yBAC9B,0DAAC,0CAAmB,QAAQ;YAAC,OAAO;yBAClC,0DAAC;YAAe,YAAY;;;AAMxC;AAoBA,MAAM,6CAAuB,CAAA,GAAA,0CAAa;AAE1C;AAFM,qCACY,OAAO;AAMlB,MAAM,4CAAa,WAAW,GAAG,CAAA,GAAA,+CAAkB,EAAE,sCAAgB,SAAS,WAAW,KAAsB,EAAE,GAAgC,EAAE,IAAmB;IAC3K,sGAAsG;IACtG,IAAI,YAAY,KAAK,OAAO,IAAI;IAChC,IAAI,cAAC,UAAU,YAAE,QAAQ,EAAC,GAAG,CAAA,GAAA,2CAAgB,EAAE;IAC/C,IAAI,YAAY;QACd,gBAAgB,YAAY,SAAS;QACrC,YAAY,cAAc;QAC1B,SAAS,IAAM,qBAAA,+BAAA,SAAW,KAAK,GAAG;IACpC;IAEA,IAAI,cAAc,CAAA,GAAA,wCAAa,EAAE;QAC/B,GAAG,KAAK,KAAK;QACb,UAAU,KAAK,QAAQ;QACvB,QAAQ;YAAC,YAAY,cAAc;uBAAW;QAAS;QACvD,kBAAkB;IACpB;IAEA,IAAI,WAAW,CAAA,GAAA,oCAAa,EAAE,OAAc;QAAC,QAAQ;IAAI;IACzD,OAAO,SAAS,EAAE;IAElB,qBACE,0DAAC;QACE,GAAG,QAAQ;QACX,GAAG,WAAW;QACf,KAAK;QACL,iBAAe,cAAc,aAAa;QAC1C,gBAAc,aAAa;qBAC3B,0DAAC,CAAA,GAAA,qCAAU,EAAE,QAAQ;QAAC,OAAO;OAC1B,YAAY,QAAQ;AAI7B","sources":["packages/react-aria-components/src/Breadcrumbs.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 */\nimport {AriaBreadcrumbsProps, useBreadcrumbs} from 'react-aria';\nimport {Collection, CollectionBuilder, CollectionNode, createLeafComponent} from '@react-aria/collections';\nimport {CollectionProps, CollectionRendererContext} from './Collection';\nimport {ContextValue, RenderProps, SlotProps, StyleProps, useContextProps, useRenderProps, useSlottedContext} from './utils';\nimport {filterDOMProps, mergeProps} from '@react-aria/utils';\nimport {forwardRefType, GlobalDOMAttributes, Key} from '@react-types/shared';\nimport {LinkContext} from './Link';\nimport {Node} from 'react-stately';\nimport React, {createContext, ForwardedRef, forwardRef, useContext} from 'react';\n\nexport interface BreadcrumbsProps<T> extends Omit<CollectionProps<T>, 'disabledKeys'>, AriaBreadcrumbsProps, StyleProps, SlotProps, GlobalDOMAttributes<HTMLOListElement> {\n /** Whether the breadcrumbs are disabled. */\n isDisabled?: boolean,\n /** Handler that is called when a breadcrumb is clicked. */\n onAction?: (key: Key) => void\n}\n\nexport const BreadcrumbsContext = createContext<ContextValue<BreadcrumbsProps<any>, HTMLOListElement>>(null);\n\n/**\n * Breadcrumbs display a hierarchy of links to the current page or resource in an application.\n */\nexport const Breadcrumbs = /*#__PURE__*/ (forwardRef as forwardRefType)(function Breadcrumbs<T extends object>(props: BreadcrumbsProps<T>, ref: ForwardedRef<HTMLOListElement>) {\n [props, ref] = useContextProps(props, ref, BreadcrumbsContext);\n let {CollectionRoot} = useContext(CollectionRendererContext);\n let {navProps} = useBreadcrumbs(props);\n let DOMProps = filterDOMProps(props, {global: true});\n\n return (\n <CollectionBuilder content={<Collection {...props} />}>\n {collection => (\n <ol\n ref={ref}\n {...mergeProps(DOMProps, navProps)}\n slot={props.slot || undefined}\n style={props.style}\n className={props.className ?? 'react-aria-Breadcrumbs'}>\n <BreadcrumbsContext.Provider value={props}>\n <CollectionRoot collection={collection} />\n </BreadcrumbsContext.Provider>\n </ol>\n )}\n </CollectionBuilder>\n );\n});\n\nexport interface BreadcrumbRenderProps {\n /**\n * Whether the breadcrumb is for the current page.\n * @selector [data-current]\n */\n isCurrent: boolean,\n /**\n * Whether the breadcrumb is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean\n}\n\nexport interface BreadcrumbProps extends RenderProps<BreadcrumbRenderProps>, GlobalDOMAttributes<HTMLLIElement> {\n /** A unique id for the breadcrumb, which will be passed to `onAction` when the breadcrumb is pressed. */\n id?: Key\n}\n\nclass BreadcrumbNode extends CollectionNode<unknown> {\n static readonly type = 'item';\n}\n\n/**\n * A Breadcrumb represents an individual item in a `<Breadcrumbs>` list.\n */\nexport const Breadcrumb = /*#__PURE__*/ createLeafComponent(BreadcrumbNode, function Breadcrumb(props: BreadcrumbProps, ref: ForwardedRef<HTMLLIElement>, node: Node<unknown>) {\n // Recreating useBreadcrumbItem because we want to use composition instead of having the link builtin.\n let isCurrent = node.nextKey == null;\n let {isDisabled, onAction} = useSlottedContext(BreadcrumbsContext)!;\n let linkProps = {\n 'aria-current': isCurrent ? 'page' : null,\n isDisabled: isDisabled || isCurrent,\n onPress: () => onAction?.(node.key)\n };\n\n let renderProps = useRenderProps({\n ...node.props,\n children: node.rendered,\n values: {isDisabled: isDisabled || isCurrent, isCurrent},\n defaultClassName: 'react-aria-Breadcrumb'\n });\n\n let DOMProps = filterDOMProps(props as any, {global: true});\n delete DOMProps.id;\n\n return (\n <li\n {...DOMProps}\n {...renderProps}\n ref={ref}\n data-disabled={isDisabled || isCurrent || undefined}\n data-current={isCurrent || undefined}>\n <LinkContext.Provider value={linkProps}>\n {renderProps.children}\n </LinkContext.Provider>\n </li>\n );\n});\n"],"names":[],"version":3,"file":"Breadcrumbs.main.js.map"}
|
package/dist/Breadcrumbs.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import {CollectionRendererContext as $7135fc7d473fd974$export$4feb769f8ddf26c5}
|
|
|
2
2
|
import {useContextProps as $64fa3d84918910a7$export$29f1550f4b0d4415, useRenderProps as $64fa3d84918910a7$export$4d86445c2cf5e3, useSlottedContext as $64fa3d84918910a7$export$fabf2dc03a41866e} from "./utils.mjs";
|
|
3
3
|
import {LinkContext as $4f118338184dc1d9$export$e2509388b49734e7} from "./Link.mjs";
|
|
4
4
|
import {useBreadcrumbs as $c5cc5$useBreadcrumbs} from "react-aria";
|
|
5
|
-
import {CollectionBuilder as $c5cc5$CollectionBuilder, Collection as $c5cc5$Collection, createLeafComponent as $c5cc5$createLeafComponent} from "@react-aria/collections";
|
|
5
|
+
import {CollectionBuilder as $c5cc5$CollectionBuilder, Collection as $c5cc5$Collection, CollectionNode as $c5cc5$CollectionNode, createLeafComponent as $c5cc5$createLeafComponent} from "@react-aria/collections";
|
|
6
6
|
import {filterDOMProps as $c5cc5$filterDOMProps, mergeProps as $c5cc5$mergeProps} from "@react-aria/utils";
|
|
7
7
|
import $c5cc5$react, {createContext as $c5cc5$createContext, forwardRef as $c5cc5$forwardRef, useContext as $c5cc5$useContext} from "react";
|
|
8
8
|
|
|
@@ -48,7 +48,10 @@ const $778035c5624f61e7$export$2dc68d50d56fbbd = /*#__PURE__*/ (0, $c5cc5$forwar
|
|
|
48
48
|
})));
|
|
49
49
|
});
|
|
50
50
|
});
|
|
51
|
-
|
|
51
|
+
class $778035c5624f61e7$var$BreadcrumbNode extends (0, $c5cc5$CollectionNode) {
|
|
52
|
+
}
|
|
53
|
+
$778035c5624f61e7$var$BreadcrumbNode.type = 'item';
|
|
54
|
+
const $778035c5624f61e7$export$dabcc1ec9dd9d1cc = /*#__PURE__*/ (0, $c5cc5$createLeafComponent)($778035c5624f61e7$var$BreadcrumbNode, function Breadcrumb(props, ref, node) {
|
|
52
55
|
// Recreating useBreadcrumbItem because we want to use composition instead of having the link builtin.
|
|
53
56
|
let isCurrent = node.nextKey == null;
|
|
54
57
|
let { isDisabled: isDisabled, onAction: onAction } = (0, $64fa3d84918910a7$export$fabf2dc03a41866e)($778035c5624f61e7$export$65596d3621b0a4a0);
|
|
@@ -2,7 +2,7 @@ import {CollectionRendererContext as $7135fc7d473fd974$export$4feb769f8ddf26c5}
|
|
|
2
2
|
import {useContextProps as $64fa3d84918910a7$export$29f1550f4b0d4415, useRenderProps as $64fa3d84918910a7$export$4d86445c2cf5e3, useSlottedContext as $64fa3d84918910a7$export$fabf2dc03a41866e} from "./utils.module.js";
|
|
3
3
|
import {LinkContext as $4f118338184dc1d9$export$e2509388b49734e7} from "./Link.module.js";
|
|
4
4
|
import {useBreadcrumbs as $c5cc5$useBreadcrumbs} from "react-aria";
|
|
5
|
-
import {CollectionBuilder as $c5cc5$CollectionBuilder, Collection as $c5cc5$Collection, createLeafComponent as $c5cc5$createLeafComponent} from "@react-aria/collections";
|
|
5
|
+
import {CollectionBuilder as $c5cc5$CollectionBuilder, Collection as $c5cc5$Collection, CollectionNode as $c5cc5$CollectionNode, createLeafComponent as $c5cc5$createLeafComponent} from "@react-aria/collections";
|
|
6
6
|
import {filterDOMProps as $c5cc5$filterDOMProps, mergeProps as $c5cc5$mergeProps} from "@react-aria/utils";
|
|
7
7
|
import $c5cc5$react, {createContext as $c5cc5$createContext, forwardRef as $c5cc5$forwardRef, useContext as $c5cc5$useContext} from "react";
|
|
8
8
|
|
|
@@ -48,7 +48,10 @@ const $778035c5624f61e7$export$2dc68d50d56fbbd = /*#__PURE__*/ (0, $c5cc5$forwar
|
|
|
48
48
|
})));
|
|
49
49
|
});
|
|
50
50
|
});
|
|
51
|
-
|
|
51
|
+
class $778035c5624f61e7$var$BreadcrumbNode extends (0, $c5cc5$CollectionNode) {
|
|
52
|
+
}
|
|
53
|
+
$778035c5624f61e7$var$BreadcrumbNode.type = 'item';
|
|
54
|
+
const $778035c5624f61e7$export$dabcc1ec9dd9d1cc = /*#__PURE__*/ (0, $c5cc5$createLeafComponent)($778035c5624f61e7$var$BreadcrumbNode, function Breadcrumb(props, ref, node) {
|
|
52
55
|
// Recreating useBreadcrumbItem because we want to use composition instead of having the link builtin.
|
|
53
56
|
let isCurrent = node.nextKey == null;
|
|
54
57
|
let { isDisabled: isDisabled, onAction: onAction } = (0, $64fa3d84918910a7$export$fabf2dc03a41866e)($778035c5624f61e7$export$65596d3621b0a4a0);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAkBM,MAAM,0DAAqB,CAAA,GAAA,oBAAY,EAAyD;AAKhG,MAAM,2CAA4B,AAAd,WAAW,GAAI,CAAA,GAAA,iBAAS,EAAqB,SAAS,YAA8B,KAA0B,EAAE,GAAmC;IAC5K,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,kBAAC,cAAc,EAAC,GAAG,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,yCAAwB;IAC1D,IAAI,YAAC,QAAQ,EAAC,GAAG,CAAA,GAAA,qBAAa,EAAE;IAChC,IAAI,WAAW,CAAA,GAAA,qBAAa,EAAE,OAAO;QAAC,QAAQ;IAAI;IAElD,qBACE,gCAAC,CAAA,GAAA,wBAAgB;QAAE,uBAAS,gCAAC,CAAA,GAAA,iBAAS,GAAM;OACzC,CAAA;YAMc;6BALb,gCAAC;YACC,KAAK;YACJ,GAAG,CAAA,GAAA,iBAAS,EAAE,UAAU,SAAS;YAClC,MAAM,MAAM,IAAI,IAAI;YACpB,OAAO,MAAM,KAAK;YAClB,WAAW,CAAA,mBAAA,MAAM,SAAS,cAAf,8BAAA,mBAAmB;yBAC9B,gCAAC,0CAAmB,QAAQ;YAAC,OAAO;yBAClC,gCAAC;YAAe,YAAY;;;AAMxC;
|
|
1
|
+
{"mappings":";;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;;;AAkBM,MAAM,0DAAqB,CAAA,GAAA,oBAAY,EAAyD;AAKhG,MAAM,2CAA4B,AAAd,WAAW,GAAI,CAAA,GAAA,iBAAS,EAAqB,SAAS,YAA8B,KAA0B,EAAE,GAAmC;IAC5K,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,kBAAC,cAAc,EAAC,GAAG,CAAA,GAAA,iBAAS,EAAE,CAAA,GAAA,yCAAwB;IAC1D,IAAI,YAAC,QAAQ,EAAC,GAAG,CAAA,GAAA,qBAAa,EAAE;IAChC,IAAI,WAAW,CAAA,GAAA,qBAAa,EAAE,OAAO;QAAC,QAAQ;IAAI;IAElD,qBACE,gCAAC,CAAA,GAAA,wBAAgB;QAAE,uBAAS,gCAAC,CAAA,GAAA,iBAAS,GAAM;OACzC,CAAA;YAMc;6BALb,gCAAC;YACC,KAAK;YACJ,GAAG,CAAA,GAAA,iBAAS,EAAE,UAAU,SAAS;YAClC,MAAM,MAAM,IAAI,IAAI;YACpB,OAAO,MAAM,KAAK;YAClB,WAAW,CAAA,mBAAA,MAAM,SAAS,cAAf,8BAAA,mBAAmB;yBAC9B,gCAAC,0CAAmB,QAAQ;YAAC,OAAO;yBAClC,gCAAC;YAAe,YAAY;;;AAMxC;AAoBA,MAAM,6CAAuB,CAAA,GAAA,qBAAa;AAE1C;AAFM,qCACY,OAAO;AAMlB,MAAM,4CAAa,WAAW,GAAG,CAAA,GAAA,0BAAkB,EAAE,sCAAgB,SAAS,WAAW,KAAsB,EAAE,GAAgC,EAAE,IAAmB;IAC3K,sGAAsG;IACtG,IAAI,YAAY,KAAK,OAAO,IAAI;IAChC,IAAI,cAAC,UAAU,YAAE,QAAQ,EAAC,GAAG,CAAA,GAAA,yCAAgB,EAAE;IAC/C,IAAI,YAAY;QACd,gBAAgB,YAAY,SAAS;QACrC,YAAY,cAAc;QAC1B,SAAS,IAAM,qBAAA,+BAAA,SAAW,KAAK,GAAG;IACpC;IAEA,IAAI,cAAc,CAAA,GAAA,uCAAa,EAAE;QAC/B,GAAG,KAAK,KAAK;QACb,UAAU,KAAK,QAAQ;QACvB,QAAQ;YAAC,YAAY,cAAc;uBAAW;QAAS;QACvD,kBAAkB;IACpB;IAEA,IAAI,WAAW,CAAA,GAAA,qBAAa,EAAE,OAAc;QAAC,QAAQ;IAAI;IACzD,OAAO,SAAS,EAAE;IAElB,qBACE,gCAAC;QACE,GAAG,QAAQ;QACX,GAAG,WAAW;QACf,KAAK;QACL,iBAAe,cAAc,aAAa;QAC1C,gBAAc,aAAa;qBAC3B,gCAAC,CAAA,GAAA,yCAAU,EAAE,QAAQ;QAAC,OAAO;OAC1B,YAAY,QAAQ;AAI7B","sources":["packages/react-aria-components/src/Breadcrumbs.tsx"],"sourcesContent":["/*\n * Copyright 2022 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 */\nimport {AriaBreadcrumbsProps, useBreadcrumbs} from 'react-aria';\nimport {Collection, CollectionBuilder, CollectionNode, createLeafComponent} from '@react-aria/collections';\nimport {CollectionProps, CollectionRendererContext} from './Collection';\nimport {ContextValue, RenderProps, SlotProps, StyleProps, useContextProps, useRenderProps, useSlottedContext} from './utils';\nimport {filterDOMProps, mergeProps} from '@react-aria/utils';\nimport {forwardRefType, GlobalDOMAttributes, Key} from '@react-types/shared';\nimport {LinkContext} from './Link';\nimport {Node} from 'react-stately';\nimport React, {createContext, ForwardedRef, forwardRef, useContext} from 'react';\n\nexport interface BreadcrumbsProps<T> extends Omit<CollectionProps<T>, 'disabledKeys'>, AriaBreadcrumbsProps, StyleProps, SlotProps, GlobalDOMAttributes<HTMLOListElement> {\n /** Whether the breadcrumbs are disabled. */\n isDisabled?: boolean,\n /** Handler that is called when a breadcrumb is clicked. */\n onAction?: (key: Key) => void\n}\n\nexport const BreadcrumbsContext = createContext<ContextValue<BreadcrumbsProps<any>, HTMLOListElement>>(null);\n\n/**\n * Breadcrumbs display a hierarchy of links to the current page or resource in an application.\n */\nexport const Breadcrumbs = /*#__PURE__*/ (forwardRef as forwardRefType)(function Breadcrumbs<T extends object>(props: BreadcrumbsProps<T>, ref: ForwardedRef<HTMLOListElement>) {\n [props, ref] = useContextProps(props, ref, BreadcrumbsContext);\n let {CollectionRoot} = useContext(CollectionRendererContext);\n let {navProps} = useBreadcrumbs(props);\n let DOMProps = filterDOMProps(props, {global: true});\n\n return (\n <CollectionBuilder content={<Collection {...props} />}>\n {collection => (\n <ol\n ref={ref}\n {...mergeProps(DOMProps, navProps)}\n slot={props.slot || undefined}\n style={props.style}\n className={props.className ?? 'react-aria-Breadcrumbs'}>\n <BreadcrumbsContext.Provider value={props}>\n <CollectionRoot collection={collection} />\n </BreadcrumbsContext.Provider>\n </ol>\n )}\n </CollectionBuilder>\n );\n});\n\nexport interface BreadcrumbRenderProps {\n /**\n * Whether the breadcrumb is for the current page.\n * @selector [data-current]\n */\n isCurrent: boolean,\n /**\n * Whether the breadcrumb is disabled.\n * @selector [data-disabled]\n */\n isDisabled: boolean\n}\n\nexport interface BreadcrumbProps extends RenderProps<BreadcrumbRenderProps>, GlobalDOMAttributes<HTMLLIElement> {\n /** A unique id for the breadcrumb, which will be passed to `onAction` when the breadcrumb is pressed. */\n id?: Key\n}\n\nclass BreadcrumbNode extends CollectionNode<unknown> {\n static readonly type = 'item';\n}\n\n/**\n * A Breadcrumb represents an individual item in a `<Breadcrumbs>` list.\n */\nexport const Breadcrumb = /*#__PURE__*/ createLeafComponent(BreadcrumbNode, function Breadcrumb(props: BreadcrumbProps, ref: ForwardedRef<HTMLLIElement>, node: Node<unknown>) {\n // Recreating useBreadcrumbItem because we want to use composition instead of having the link builtin.\n let isCurrent = node.nextKey == null;\n let {isDisabled, onAction} = useSlottedContext(BreadcrumbsContext)!;\n let linkProps = {\n 'aria-current': isCurrent ? 'page' : null,\n isDisabled: isDisabled || isCurrent,\n onPress: () => onAction?.(node.key)\n };\n\n let renderProps = useRenderProps({\n ...node.props,\n children: node.rendered,\n values: {isDisabled: isDisabled || isCurrent, isCurrent},\n defaultClassName: 'react-aria-Breadcrumb'\n });\n\n let DOMProps = filterDOMProps(props as any, {global: true});\n delete DOMProps.id;\n\n return (\n <li\n {...DOMProps}\n {...renderProps}\n ref={ref}\n data-disabled={isDisabled || isCurrent || undefined}\n data-current={isCurrent || undefined}>\n <LinkContext.Provider value={linkProps}>\n {renderProps.children}\n </LinkContext.Provider>\n </li>\n );\n});\n"],"names":[],"version":3,"file":"Breadcrumbs.module.js.map"}
|
package/dist/GridList.main.js
CHANGED
|
@@ -3,6 +3,8 @@ var $525402dfec7da5bc$exports = require("./RSPContexts.main.js");
|
|
|
3
3
|
var $3114c2382242bdc0$exports = require("./Collection.main.js");
|
|
4
4
|
var $c5ccf687772c0422$exports = require("./utils.main.js");
|
|
5
5
|
var $0c2289d253cb4544$exports = require("./DragAndDrop.main.js");
|
|
6
|
+
var $09cb5ee89bb327e1$exports = require("./context.main.js");
|
|
7
|
+
var $c7efb75a1a3fe2d2$exports = require("./Header.main.js");
|
|
6
8
|
var $a03b42240404b420$exports = require("./ListBox.main.js");
|
|
7
9
|
var $a8a589c28affdc40$exports = require("./Text.main.js");
|
|
8
10
|
var $UaDUV$reactaria = require("react-aria");
|
|
@@ -24,6 +26,8 @@ $parcel$export(module.exports, "GridListContext", () => $132cbde493282f82$export
|
|
|
24
26
|
$parcel$export(module.exports, "GridList", () => $132cbde493282f82$export$a7bfbda1311ca015);
|
|
25
27
|
$parcel$export(module.exports, "GridListItem", () => $132cbde493282f82$export$e96fc9a8407faa6b);
|
|
26
28
|
$parcel$export(module.exports, "GridListLoadMoreItem", () => $132cbde493282f82$export$392b9a0bbc7c7e43);
|
|
29
|
+
$parcel$export(module.exports, "GridListSection", () => $132cbde493282f82$export$f696877219115b14);
|
|
30
|
+
$parcel$export(module.exports, "GridListHeader", () => $132cbde493282f82$export$1b574dbdb0075ff6);
|
|
27
31
|
/*
|
|
28
32
|
* Copyright 2022 Adobe. All rights reserved.
|
|
29
33
|
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
|
|
@@ -46,6 +50,8 @@ $parcel$export(module.exports, "GridListLoadMoreItem", () => $132cbde493282f82$e
|
|
|
46
50
|
|
|
47
51
|
|
|
48
52
|
|
|
53
|
+
|
|
54
|
+
|
|
49
55
|
const $132cbde493282f82$export$54fe942636b6416d = /*#__PURE__*/ (0, $UaDUV$react.createContext)(null);
|
|
50
56
|
const $132cbde493282f82$export$a7bfbda1311ca015 = /*#__PURE__*/ (0, $UaDUV$react.forwardRef)(function GridList(props, ref) {
|
|
51
57
|
// Render the portal first so that we have the collection by the time we render the DOM in SSR.
|
|
@@ -59,22 +65,30 @@ const $132cbde493282f82$export$a7bfbda1311ca015 = /*#__PURE__*/ (0, $UaDUV$react
|
|
|
59
65
|
}));
|
|
60
66
|
});
|
|
61
67
|
function $132cbde493282f82$var$GridListInner({ props: props, collection: collection, gridListRef: ref }) {
|
|
68
|
+
// TODO: for now, don't grab collection ref and collectionProps from the autocomplete, rely on the user tabbing to the gridlist
|
|
69
|
+
// figure out if we want to support virtual focus for grids when wrapped in an autocomplete
|
|
70
|
+
let contextProps;
|
|
71
|
+
[contextProps] = (0, $c5ccf687772c0422$exports.useContextProps)({}, null, (0, $09cb5ee89bb327e1$exports.SelectableCollectionContext));
|
|
72
|
+
let { filter: filter, ...collectionProps } = contextProps;
|
|
73
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
74
|
+
let { shouldUseVirtualFocus: shouldUseVirtualFocus, disallowTypeAhead: disallowTypeAhead, ...DOMCollectionProps } = collectionProps || {};
|
|
62
75
|
let { dragAndDropHooks: dragAndDropHooks, keyboardNavigationBehavior: keyboardNavigationBehavior = 'arrow', layout: layout = 'stack' } = props;
|
|
63
76
|
let { CollectionRoot: CollectionRoot, isVirtualized: isVirtualized, layoutDelegate: layoutDelegate, dropTargetDelegate: ctxDropTargetDelegate } = (0, $UaDUV$react.useContext)((0, $3114c2382242bdc0$exports.CollectionRendererContext));
|
|
64
|
-
let
|
|
77
|
+
let gridlistState = (0, $UaDUV$reactstately.useListState)({
|
|
65
78
|
...props,
|
|
66
79
|
collection: collection,
|
|
67
80
|
children: undefined,
|
|
68
81
|
layoutDelegate: layoutDelegate
|
|
69
82
|
});
|
|
83
|
+
let filteredState = (0, $UaDUV$reactstately.UNSTABLE_useFilteredListState)(gridlistState, filter);
|
|
70
84
|
let collator = (0, $UaDUV$reactaria.useCollator)({
|
|
71
85
|
usage: 'search',
|
|
72
86
|
sensitivity: 'base'
|
|
73
87
|
});
|
|
74
|
-
let { disabledBehavior: disabledBehavior, disabledKeys: disabledKeys } =
|
|
88
|
+
let { disabledBehavior: disabledBehavior, disabledKeys: disabledKeys } = filteredState.selectionManager;
|
|
75
89
|
let { direction: direction } = (0, $UaDUV$reactaria.useLocale)();
|
|
76
90
|
let keyboardDelegate = (0, $UaDUV$react.useMemo)(()=>new (0, $UaDUV$reactaria.ListKeyboardDelegate)({
|
|
77
|
-
collection: collection,
|
|
91
|
+
collection: filteredState.collection,
|
|
78
92
|
collator: collator,
|
|
79
93
|
ref: ref,
|
|
80
94
|
disabledKeys: disabledKeys,
|
|
@@ -83,7 +97,7 @@ function $132cbde493282f82$var$GridListInner({ props: props, collection: collect
|
|
|
83
97
|
layout: layout,
|
|
84
98
|
direction: direction
|
|
85
99
|
}), [
|
|
86
|
-
collection,
|
|
100
|
+
filteredState.collection,
|
|
87
101
|
ref,
|
|
88
102
|
layout,
|
|
89
103
|
disabledKeys,
|
|
@@ -94,13 +108,14 @@ function $132cbde493282f82$var$GridListInner({ props: props, collection: collect
|
|
|
94
108
|
]);
|
|
95
109
|
let { gridProps: gridProps } = (0, $UaDUV$reactaria.useGridList)({
|
|
96
110
|
...props,
|
|
111
|
+
...DOMCollectionProps,
|
|
97
112
|
keyboardDelegate: keyboardDelegate,
|
|
98
113
|
// Only tab navigation is supported in grid layout.
|
|
99
114
|
keyboardNavigationBehavior: layout === 'grid' ? 'tab' : keyboardNavigationBehavior,
|
|
100
115
|
isVirtualized: isVirtualized,
|
|
101
116
|
shouldSelectOnPressUp: props.shouldSelectOnPressUp
|
|
102
|
-
},
|
|
103
|
-
let selectionManager =
|
|
117
|
+
}, filteredState, ref);
|
|
118
|
+
let selectionManager = filteredState.selectionManager;
|
|
104
119
|
let isListDraggable = !!(dragAndDropHooks === null || dragAndDropHooks === void 0 ? void 0 : dragAndDropHooks.useDraggableCollectionState);
|
|
105
120
|
let isListDroppable = !!(dragAndDropHooks === null || dragAndDropHooks === void 0 ? void 0 : dragAndDropHooks.useDroppableCollectionState);
|
|
106
121
|
let dragHooksProvided = (0, $UaDUV$react.useRef)(isListDraggable);
|
|
@@ -121,7 +136,7 @@ function $132cbde493282f82$var$GridListInner({ props: props, collection: collect
|
|
|
121
136
|
let preview = (0, $UaDUV$react.useRef)(null);
|
|
122
137
|
if (isListDraggable && dragAndDropHooks) {
|
|
123
138
|
dragState = dragAndDropHooks.useDraggableCollectionState({
|
|
124
|
-
collection: collection,
|
|
139
|
+
collection: filteredState.collection,
|
|
125
140
|
selectionManager: selectionManager,
|
|
126
141
|
preview: dragAndDropHooks.renderDragPreview ? preview : undefined
|
|
127
142
|
});
|
|
@@ -133,11 +148,11 @@ function $132cbde493282f82$var$GridListInner({ props: props, collection: collect
|
|
|
133
148
|
}
|
|
134
149
|
if (isListDroppable && dragAndDropHooks) {
|
|
135
150
|
dropState = dragAndDropHooks.useDroppableCollectionState({
|
|
136
|
-
collection: collection,
|
|
151
|
+
collection: filteredState.collection,
|
|
137
152
|
selectionManager: selectionManager
|
|
138
153
|
});
|
|
139
154
|
let keyboardDelegate = new (0, $UaDUV$reactaria.ListKeyboardDelegate)({
|
|
140
|
-
collection: collection,
|
|
155
|
+
collection: filteredState.collection,
|
|
141
156
|
disabledKeys: selectionManager.disabledKeys,
|
|
142
157
|
disabledBehavior: selectionManager.disabledBehavior,
|
|
143
158
|
ref: ref
|
|
@@ -155,14 +170,14 @@ function $132cbde493282f82$var$GridListInner({ props: props, collection: collect
|
|
|
155
170
|
});
|
|
156
171
|
}
|
|
157
172
|
let { focusProps: focusProps, isFocused: isFocused, isFocusVisible: isFocusVisible } = (0, $UaDUV$reactaria.useFocusRing)();
|
|
158
|
-
let isEmpty =
|
|
173
|
+
let isEmpty = filteredState.collection.size === 0;
|
|
159
174
|
let renderValues = {
|
|
160
175
|
isDropTarget: isRootDropTarget,
|
|
161
176
|
isEmpty: isEmpty,
|
|
162
177
|
isFocused: isFocused,
|
|
163
178
|
isFocusVisible: isFocusVisible,
|
|
164
179
|
layout: layout,
|
|
165
|
-
state:
|
|
180
|
+
state: filteredState
|
|
166
181
|
};
|
|
167
182
|
let renderProps = (0, $c5ccf687772c0422$exports.useRenderProps)({
|
|
168
183
|
className: props.className,
|
|
@@ -204,7 +219,7 @@ function $132cbde493282f82$var$GridListInner({ props: props, collection: collect
|
|
|
204
219
|
values: [
|
|
205
220
|
[
|
|
206
221
|
(0, $a03b42240404b420$exports.ListStateContext),
|
|
207
|
-
|
|
222
|
+
filteredState
|
|
208
223
|
],
|
|
209
224
|
[
|
|
210
225
|
(0, $0c2289d253cb4544$exports.DragAndDropContext),
|
|
@@ -222,13 +237,13 @@ function $132cbde493282f82$var$GridListInner({ props: props, collection: collect
|
|
|
222
237
|
]
|
|
223
238
|
]
|
|
224
239
|
}, isListDroppable && /*#__PURE__*/ (0, ($parcel$interopDefault($UaDUV$react))).createElement($132cbde493282f82$var$RootDropIndicator, null), /*#__PURE__*/ (0, ($parcel$interopDefault($UaDUV$react))).createElement(CollectionRoot, {
|
|
225
|
-
collection: collection,
|
|
240
|
+
collection: filteredState.collection,
|
|
226
241
|
scrollRef: ref,
|
|
227
242
|
persistedKeys: (0, $0c2289d253cb4544$exports.useDndPersistedKeys)(selectionManager, dragAndDropHooks, dropState),
|
|
228
243
|
renderDropIndicator: (0, $0c2289d253cb4544$exports.useRenderDropIndicator)(dragAndDropHooks, dropState)
|
|
229
244
|
})), emptyState, dragPreview));
|
|
230
245
|
}
|
|
231
|
-
const $132cbde493282f82$export$e96fc9a8407faa6b = /*#__PURE__*/ (0, $UaDUV$reactariacollections.createLeafComponent)(
|
|
246
|
+
const $132cbde493282f82$export$e96fc9a8407faa6b = /*#__PURE__*/ (0, $UaDUV$reactariacollections.createLeafComponent)((0, $UaDUV$reactariacollections.ItemNode), function GridListItem(props, forwardedRef, item) {
|
|
232
247
|
let state = (0, $UaDUV$react.useContext)((0, $a03b42240404b420$exports.ListStateContext));
|
|
233
248
|
let { dragAndDropHooks: dragAndDropHooks, dragState: dragState, dropState: dropState } = (0, $UaDUV$react.useContext)((0, $0c2289d253cb4544$exports.DragAndDropContext));
|
|
234
249
|
let ref = (0, $UaDUV$reactariautils.useObjectRef)(forwardedRef);
|
|
@@ -370,6 +385,14 @@ const $132cbde493282f82$export$e96fc9a8407faa6b = /*#__PURE__*/ (0, $UaDUV$react
|
|
|
370
385
|
[
|
|
371
386
|
(0, $a03b42240404b420$exports.ListStateContext),
|
|
372
387
|
null
|
|
388
|
+
],
|
|
389
|
+
[
|
|
390
|
+
(0, $09cb5ee89bb327e1$exports.SelectableCollectionContext),
|
|
391
|
+
null
|
|
392
|
+
],
|
|
393
|
+
[
|
|
394
|
+
(0, $09cb5ee89bb327e1$exports.FieldInputContext),
|
|
395
|
+
null
|
|
373
396
|
]
|
|
374
397
|
]
|
|
375
398
|
}, renderProps.children))));
|
|
@@ -441,7 +464,7 @@ function $132cbde493282f82$var$RootDropIndicator() {
|
|
|
441
464
|
ref: ref
|
|
442
465
|
})));
|
|
443
466
|
}
|
|
444
|
-
const $132cbde493282f82$export$392b9a0bbc7c7e43 = (0, $UaDUV$reactariacollections.createLeafComponent)(
|
|
467
|
+
const $132cbde493282f82$export$392b9a0bbc7c7e43 = (0, $UaDUV$reactariacollections.createLeafComponent)((0, $UaDUV$reactariacollections.LoaderNode), function GridListLoadingIndicator(props, ref, item) {
|
|
445
468
|
let state = (0, $UaDUV$react.useContext)((0, $a03b42240404b420$exports.ListStateContext));
|
|
446
469
|
let { isVirtualized: isVirtualized } = (0, $UaDUV$react.useContext)((0, $3114c2382242bdc0$exports.CollectionRendererContext));
|
|
447
470
|
let { isLoading: isLoading, onLoadMore: onLoadMore, scrollOffset: scrollOffset, ...otherProps } = props;
|
|
@@ -494,6 +517,64 @@ const $132cbde493282f82$export$392b9a0bbc7c7e43 = (0, $UaDUV$reactariacollection
|
|
|
494
517
|
role: "gridcell"
|
|
495
518
|
}, renderProps.children)));
|
|
496
519
|
});
|
|
520
|
+
const $132cbde493282f82$export$f696877219115b14 = /*#__PURE__*/ (0, $UaDUV$reactariacollections.createBranchComponent)((0, $UaDUV$reactariacollections.SectionNode), (props, ref, item)=>{
|
|
521
|
+
let state = (0, $UaDUV$react.useContext)((0, $a03b42240404b420$exports.ListStateContext));
|
|
522
|
+
let { CollectionBranch: CollectionBranch } = (0, $UaDUV$react.useContext)((0, $3114c2382242bdc0$exports.CollectionRendererContext));
|
|
523
|
+
let headingRef = (0, $UaDUV$react.useRef)(null);
|
|
524
|
+
ref = (0, $UaDUV$reactariautils.useObjectRef)(ref);
|
|
525
|
+
var _props_arialabel;
|
|
526
|
+
let { rowHeaderProps: rowHeaderProps, rowProps: rowProps, rowGroupProps: rowGroupProps } = (0, $UaDUV$reactaria.useGridListSection)({
|
|
527
|
+
'aria-label': (_props_arialabel = props['aria-label']) !== null && _props_arialabel !== void 0 ? _props_arialabel : undefined
|
|
528
|
+
}, state, ref);
|
|
529
|
+
let renderProps = (0, $c5ccf687772c0422$exports.useRenderProps)({
|
|
530
|
+
defaultClassName: 'react-aria-GridListSection',
|
|
531
|
+
className: props.className,
|
|
532
|
+
style: props.style,
|
|
533
|
+
values: {}
|
|
534
|
+
});
|
|
535
|
+
let DOMProps = (0, $UaDUV$reactariautils.filterDOMProps)(props, {
|
|
536
|
+
global: true
|
|
537
|
+
});
|
|
538
|
+
delete DOMProps.id;
|
|
539
|
+
return /*#__PURE__*/ (0, ($parcel$interopDefault($UaDUV$react))).createElement("section", {
|
|
540
|
+
...(0, $UaDUV$reactaria.mergeProps)(DOMProps, renderProps, rowGroupProps),
|
|
541
|
+
ref: ref
|
|
542
|
+
}, /*#__PURE__*/ (0, ($parcel$interopDefault($UaDUV$react))).createElement((0, $c5ccf687772c0422$exports.Provider), {
|
|
543
|
+
values: [
|
|
544
|
+
[
|
|
545
|
+
(0, $c7efb75a1a3fe2d2$exports.HeaderContext),
|
|
546
|
+
{
|
|
547
|
+
...rowProps,
|
|
548
|
+
ref: headingRef
|
|
549
|
+
}
|
|
550
|
+
],
|
|
551
|
+
[
|
|
552
|
+
$132cbde493282f82$var$GridListHeaderContext,
|
|
553
|
+
{
|
|
554
|
+
...rowHeaderProps
|
|
555
|
+
}
|
|
556
|
+
]
|
|
557
|
+
]
|
|
558
|
+
}, /*#__PURE__*/ (0, ($parcel$interopDefault($UaDUV$react))).createElement(CollectionBranch, {
|
|
559
|
+
collection: state.collection,
|
|
560
|
+
parent: item
|
|
561
|
+
})));
|
|
562
|
+
});
|
|
563
|
+
const $132cbde493282f82$var$GridListHeaderContext = /*#__PURE__*/ (0, $UaDUV$react.createContext)(null);
|
|
564
|
+
const $132cbde493282f82$export$1b574dbdb0075ff6 = /*#__PURE__*/ (0, $UaDUV$reactariacollections.createLeafComponent)((0, $UaDUV$reactariacollections.HeaderNode), function Header(props, ref) {
|
|
565
|
+
[props, ref] = (0, $c5ccf687772c0422$exports.useContextProps)(props, ref, (0, $c7efb75a1a3fe2d2$exports.HeaderContext));
|
|
566
|
+
let rowHeaderProps = (0, $UaDUV$react.useContext)($132cbde493282f82$var$GridListHeaderContext);
|
|
567
|
+
return /*#__PURE__*/ (0, ($parcel$interopDefault($UaDUV$react))).createElement("header", {
|
|
568
|
+
className: "react-aria-GridListHeader",
|
|
569
|
+
ref: ref,
|
|
570
|
+
...props
|
|
571
|
+
}, /*#__PURE__*/ (0, ($parcel$interopDefault($UaDUV$react))).createElement("div", {
|
|
572
|
+
...rowHeaderProps,
|
|
573
|
+
style: {
|
|
574
|
+
display: 'contents'
|
|
575
|
+
}
|
|
576
|
+
}, props.children));
|
|
577
|
+
});
|
|
497
578
|
|
|
498
579
|
|
|
499
580
|
//# sourceMappingURL=GridList.main.js.map
|