44 lines
1.5 KiB
JavaScript
44 lines
1.5 KiB
JavaScript
'use client';
|
|
"use strict";
|
|
Object.defineProperty(exports, "__esModule", {
|
|
value: true
|
|
});
|
|
Object.defineProperty(exports, "useTeachingPopoverCarouselNav_unstable", {
|
|
enumerable: true,
|
|
get: function() {
|
|
return useTeachingPopoverCarouselNav_unstable;
|
|
}
|
|
});
|
|
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
const _reacttabster = require("@fluentui/react-tabster");
|
|
const _reactutilities = require("@fluentui/react-utilities");
|
|
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
const _useCarouselValues = require("../TeachingPopoverCarousel/Carousel/useCarouselValues");
|
|
const useTeachingPopoverCarouselNav_unstable = (props, ref)=>{
|
|
const focusableGroupAttr = (0, _reacttabster.useArrowNavigationGroup)({
|
|
circular: false,
|
|
axis: 'horizontal',
|
|
memorizeCurrent: false,
|
|
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
unstable_hasDefault: true
|
|
});
|
|
const values = (0, _useCarouselValues.useCarouselValues_unstable)((snapshot)=>snapshot);
|
|
return {
|
|
values,
|
|
renderNavButton: props.children,
|
|
components: {
|
|
root: 'div'
|
|
},
|
|
root: _reactutilities.slot.always((0, _reactutilities.getIntrinsicElementProps)('div', {
|
|
ref,
|
|
role: 'tablist',
|
|
tabIndex: 0,
|
|
...props,
|
|
...focusableGroupAttr,
|
|
children: null
|
|
}), {
|
|
elementType: 'div'
|
|
})
|
|
};
|
|
};
|