Initial commit

This commit is contained in:
2025-03-07 19:22:02 +01:00
commit 4a98255d83
55743 changed files with 5280367 additions and 0 deletions
@@ -0,0 +1,19 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "TeachingPopover", {
enumerable: true,
get: function() {
return TeachingPopover;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useTeachingPopover = require("./useTeachingPopover");
const _renderTeachingPopover = require("./renderTeachingPopover");
const TeachingPopover = (props)=>{
const state = (0, _useTeachingPopover.useTeachingPopover_unstable)(props);
return (0, _renderTeachingPopover.renderTeachingPopover_unstable)(state);
};
TeachingPopover.displayName = 'TeachingPopover';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopover/TeachingPopover.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useTeachingPopover_unstable } from './useTeachingPopover';\nimport { renderTeachingPopover_unstable } from './renderTeachingPopover';\nimport type { TeachingPopoverProps } from './TeachingPopover.types';\n\n/**\n * An extension class of Popover which defaults to withArrow and FocusTrap enabled.\n */\nexport const TeachingPopover: React.FC<TeachingPopoverProps> = props => {\n const state = useTeachingPopover_unstable(props);\n\n return renderTeachingPopover_unstable(state);\n};\n\nTeachingPopover.displayName = 'TeachingPopover';\n"],"names":["TeachingPopover","props","state","useTeachingPopover_unstable","renderTeachingPopover_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;","mappings":";;;;+BAQaA;;;eAAAA;;;;iEARU;oCACqB;uCACG;AAMxC,MAAMA,kBAAkDC,CAAAA;IAC7D,MAAMC,QAAQC,IAAAA,+CAAAA,EAA4BF;IAE1C,OAAOG,IAAAA,qDAAAA,EAA+BF;AACxC;AAEAF,gBAAgBK,WAAW,GAAG"}
@@ -0,0 +1,6 @@
/**
* TeachingPopover State
*/ "use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopover/TeachingPopover.types.ts"],"sourcesContent":["import type { PopoverState, PopoverProps } from '@fluentui/react-popover';\n\n/**\n * TeachingPopover Props\n */\nexport type TeachingPopoverProps = PopoverProps;\n\n/**\n * TeachingPopover State\n */\nexport type TeachingPopoverState = PopoverState;\n"],"names":[],"rangeMappings":";;","mappings":"AAOA;;CAEC"}
@@ -0,0 +1,24 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
TeachingPopover: function() {
return _TeachingPopover.TeachingPopover;
},
renderTeachingPopover_unstable: function() {
return _renderTeachingPopover.renderTeachingPopover_unstable;
},
useTeachingPopover_unstable: function() {
return _useTeachingPopover.useTeachingPopover_unstable;
}
});
const _TeachingPopover = require("./TeachingPopover");
const _renderTeachingPopover = require("./renderTeachingPopover");
const _useTeachingPopover = require("./useTeachingPopover");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopover/index.ts"],"sourcesContent":["export { TeachingPopover } from './TeachingPopover';\nexport type { TeachingPopoverProps, TeachingPopoverState } from './TeachingPopover.types';\nexport { renderTeachingPopover_unstable } from './renderTeachingPopover';\nexport { useTeachingPopover_unstable } from './useTeachingPopover';\n"],"names":["TeachingPopover","renderTeachingPopover_unstable","useTeachingPopover_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,eAAe;eAAfA,gCAAe;;IAEfC,8BAA8B;eAA9BA,qDAA8B;;IAC9BC,2BAA2B;eAA3BA,+CAA2B;;;iCAHJ;uCAEe;oCACH"}
@@ -0,0 +1,12 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderTeachingPopover_unstable", {
enumerable: true,
get: function() {
return renderTeachingPopover_unstable;
}
});
const _reactpopover = require("@fluentui/react-popover");
const renderTeachingPopover_unstable = _reactpopover.renderPopover_unstable;
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopover/renderTeachingPopover.tsx"],"sourcesContent":["import { renderPopover_unstable } from '@fluentui/react-popover';\n\n/**\n * Render the final JSX of TeachingPopover\n */\nexport const renderTeachingPopover_unstable = renderPopover_unstable;\n"],"names":["renderTeachingPopover_unstable","renderPopover_unstable"],"rangeMappings":";;;;;;;;;;;","mappings":";;;;+BAKaA;;;eAAAA;;;8BAL0B;AAKhC,MAAMA,iCAAiCC,oCAAAA"}
@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useTeachingPopover_unstable", {
enumerable: true,
get: function() {
return useTeachingPopover_unstable;
}
});
const _reactpopover = require("@fluentui/react-popover");
const useTeachingPopover_unstable = (props)=>{
const popoverState = (0, _reactpopover.usePopover_unstable)(props);
var _props_withArrow, _props_trapFocus;
return {
...popoverState,
withArrow: (_props_withArrow = props.withArrow) !== null && _props_withArrow !== void 0 ? _props_withArrow : true,
// We trap focus because the default TeachingPopover view has buttons/carousel.
trapFocus: (_props_trapFocus = props.trapFocus) !== null && _props_trapFocus !== void 0 ? _props_trapFocus : true
};
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopover/useTeachingPopover.ts"],"sourcesContent":["import { usePopover_unstable } from '@fluentui/react-popover';\nimport type { TeachingPopoverProps, TeachingPopoverState } from './TeachingPopover.types';\n\nexport const useTeachingPopover_unstable = (props: TeachingPopoverProps): TeachingPopoverState => {\n const popoverState = usePopover_unstable(props);\n\n return {\n ...popoverState,\n withArrow: props.withArrow ?? true,\n // We trap focus because the default TeachingPopover view has buttons/carousel.\n trapFocus: props.trapFocus ?? true,\n };\n};\n"],"names":["useTeachingPopover_unstable","props","popoverState","usePopover_unstable","withArrow","trapFocus"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAGaA;;;eAAAA;;;8BAHuB;AAG7B,MAAMA,8BAA8B,CAACC;IAC1C,MAAMC,eAAeC,IAAAA,iCAAAA,EAAoBF;QAI5BA,kBAEAA;IAJb,OAAO;QACL,GAAGC,YAAY;QACfE,WAAWH,CAAAA,mBAAAA,MAAMG,SAAS,AAATA,MAAS,QAAfH,qBAAAA,KAAAA,IAAAA,mBAAmB;QAC9B,+EAA+E;QAC/EI,WAAWJ,CAAAA,mBAAAA,MAAMI,SAAS,AAATA,MAAS,QAAfJ,qBAAAA,KAAAA,IAAAA,mBAAmB;IAChC;AACF"}
@@ -0,0 +1,23 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "TeachingPopoverBody", {
enumerable: true,
get: function() {
return TeachingPopoverBody;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useTeachingPopoverBody = require("./useTeachingPopoverBody");
const _renderTeachingPopoverBody = require("./renderTeachingPopoverBody");
const _useTeachingPopoverBodyStylesstyles = require("./useTeachingPopoverBodyStyles.styles");
const _reactsharedcontexts = require("@fluentui/react-shared-contexts");
const TeachingPopoverBody = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useTeachingPopoverBody.useTeachingPopoverBody_unstable)(props, ref);
(0, _useTeachingPopoverBodyStylesstyles.useTeachingPopoverBodyStyles_unstable)(state);
(0, _reactsharedcontexts.useCustomStyleHook_unstable)('useTeachingPopoverBodyStyles_unstable')(state);
return (0, _renderTeachingPopoverBody.renderTeachingPopoverBody_unstable)(state);
});
TeachingPopoverBody.displayName = 'TeachingPopoverBody';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverBody/TeachingPopoverBody.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useTeachingPopoverBody_unstable } from './useTeachingPopoverBody';\nimport { renderTeachingPopoverBody_unstable } from './renderTeachingPopoverBody';\nimport { useTeachingPopoverBodyStyles_unstable } from './useTeachingPopoverBodyStyles.styles';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\nimport type { TeachingPopoverBodyProps } from './TeachingPopoverBody.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * Define a styled TeachingPopoverBody, using the `useTeachingPopoverBody_unstable` and `useTeachingPopoverBodyStyles_unstable`\n * hooks.\n *\n * TeachingPopoverBody is used to host content within a TeachingPopover, and provides a standardized media slot\n */\nexport const TeachingPopoverBody: ForwardRefComponent<TeachingPopoverBodyProps> = React.forwardRef((props, ref) => {\n const state = useTeachingPopoverBody_unstable(props, ref);\n\n useTeachingPopoverBodyStyles_unstable(state);\n\n useCustomStyleHook_unstable('useTeachingPopoverBodyStyles_unstable')(state);\n\n return renderTeachingPopoverBody_unstable(state);\n});\n\nTeachingPopoverBody.displayName = 'TeachingPopoverBody';\n"],"names":["TeachingPopoverBody","React","forwardRef","props","ref","state","useTeachingPopoverBody_unstable","useTeachingPopoverBodyStyles_unstable","useCustomStyleHook_unstable","renderTeachingPopoverBody_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAcaA;;;eAAAA;;;;iEAdU;wCACyB;2CACG;oDACG;qCACV;AAUrC,MAAMA,sBAAAA,WAAAA,GAAqEC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IACzG,MAAMC,QAAQC,IAAAA,uDAAAA,EAAgCH,OAAOC;IAErDG,IAAAA,yEAAAA,EAAsCF;IAEtCG,IAAAA,gDAAAA,EAA4B,yCAAyCH;IAErE,OAAOI,IAAAA,6DAAAA,EAAmCJ;AAC5C;AAEAL,oBAAoBU,WAAW,GAAG"}
@@ -0,0 +1,4 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverBody/TeachingPopoverBody.types.ts"],"sourcesContent":["import { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type TeachingPopoverBodySlots = {\n /**\n * The element wrapping the buttons.\n */\n root: NonNullable<Slot<'div'>>;\n /**\n * Optional Media Content.\n */\n media?: Slot<'span'>;\n};\n\nexport type TeachingPopoverBodyProps = ComponentProps<TeachingPopoverBodySlots> & {\n mediaLength?: 'short' | 'medium' | 'tall';\n};\n\nexport type TeachingPopoverBodyState = ComponentState<TeachingPopoverBodySlots> &\n Required<Pick<TeachingPopoverBodyProps, 'mediaLength'>>;\n"],"names":[],"rangeMappings":"","mappings":""}
@@ -0,0 +1,34 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
TeachingPopoverBody: function() {
return _TeachingPopoverBody.TeachingPopoverBody;
},
renderTeachingPopoverBody_unstable: function() {
return _renderTeachingPopoverBody.renderTeachingPopoverBody_unstable;
},
teachingPopoverBodyClassNames: function() {
return _useTeachingPopoverBodyStylesstyles.teachingPopoverBodyClassNames;
},
useMediaStyles: function() {
return _useTeachingPopoverBodyStylesstyles.useMediaStyles;
},
useTeachingPopoverBodyStyles_unstable: function() {
return _useTeachingPopoverBodyStylesstyles.useTeachingPopoverBodyStyles_unstable;
},
useTeachingPopoverBody_unstable: function() {
return _useTeachingPopoverBody.useTeachingPopoverBody_unstable;
}
});
const _TeachingPopoverBody = require("./TeachingPopoverBody");
const _renderTeachingPopoverBody = require("./renderTeachingPopoverBody");
const _useTeachingPopoverBody = require("./useTeachingPopoverBody");
const _useTeachingPopoverBodyStylesstyles = require("./useTeachingPopoverBodyStyles.styles");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverBody/index.ts"],"sourcesContent":["export { TeachingPopoverBody } from './TeachingPopoverBody';\nexport type {\n TeachingPopoverBodyProps,\n TeachingPopoverBodySlots,\n TeachingPopoverBodyState,\n} from './TeachingPopoverBody.types';\nexport { renderTeachingPopoverBody_unstable } from './renderTeachingPopoverBody';\nexport { useTeachingPopoverBody_unstable } from './useTeachingPopoverBody';\nexport {\n teachingPopoverBodyClassNames,\n useMediaStyles,\n useTeachingPopoverBodyStyles_unstable,\n} from './useTeachingPopoverBodyStyles.styles';\n"],"names":["TeachingPopoverBody","renderTeachingPopoverBody_unstable","teachingPopoverBodyClassNames","useMediaStyles","useTeachingPopoverBodyStyles_unstable","useTeachingPopoverBody_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,mBAAmB;eAAnBA,wCAAmB;;IAMnBC,kCAAkC;eAAlCA,6DAAkC;;IAGzCC,6BAA6B;eAA7BA,iEAA6B;;IAC7BC,cAAc;eAAdA,kDAAc;;IACdC,qCAAqC;eAArCA,yEAAqC;;IAJ9BC,+BAA+B;eAA/BA,uDAA+B;;;qCAPJ;2CAMe;wCACH;oDAKzC"}
@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderTeachingPopoverBody_unstable", {
enumerable: true,
get: function() {
return renderTeachingPopoverBody_unstable;
}
});
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
const _reactutilities = require("@fluentui/react-utilities");
const renderTeachingPopoverBody_unstable = (state)=>{
(0, _reactutilities.assertSlots)(state);
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(state.root, {
children: [
state.media && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.media, {}),
state.root.children
]
});
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverBody/renderTeachingPopoverBody.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\nimport type { TeachingPopoverBodyState } from './TeachingPopoverBody.types';\nimport { TeachingPopoverBodySlots } from './TeachingPopoverBody.types';\nimport { assertSlots } from '@fluentui/react-utilities';\n\n/**\n * Render the final JSX of TeachingPopoverBody\n */\nexport const renderTeachingPopoverBody_unstable = (state: TeachingPopoverBodyState) => {\n assertSlots<TeachingPopoverBodySlots>(state);\n\n return (\n <state.root>\n {state.media && <state.media />}\n {state.root.children}\n </state.root>\n );\n};\n"],"names":["renderTeachingPopoverBody_unstable","state","assertSlots","_jsxs","root","media","_jsx","children"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;gCAG4B;AAKrB,MAAMA,qCAAqC,CAACC;IACjDC,IAAAA,2BAAAA,EAAsCD;IAEtC,OAAA,WAAA,GACEE,IAAAA,gBAAA,EAACF,MAAMG,IAAI,EAAA;;YACRH,MAAMI,KAAK,IAAA,WAAA,GAAIC,IAAAA,eAAA,EAACL,MAAMI,KAAK,EAAA,CAAA;YAC3BJ,MAAMG,IAAI,CAACG,QAAQ;;;AAG1B"}
@@ -0,0 +1,32 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useTeachingPopoverBody_unstable", {
enumerable: true,
get: function() {
return useTeachingPopoverBody_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _reactutilities = require("@fluentui/react-utilities");
const useTeachingPopoverBody_unstable = (props, ref)=>{
const { mediaLength } = props;
return {
components: {
root: 'div',
media: 'span'
},
root: _reactutilities.slot.always((0, _reactutilities.getIntrinsicElementProps)('div', {
ref,
...props
}), {
elementType: 'div'
}),
media: _reactutilities.slot.optional(props.media, {
elementType: 'span'
}),
mediaLength: mediaLength !== null && mediaLength !== void 0 ? mediaLength : 'short'
};
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverBody/useTeachingPopoverBody.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';\nimport type { TeachingPopoverBodyProps, TeachingPopoverBodyState } from './TeachingPopoverBody.types';\n/**\n * Returns the props and state required to render the component\n * @param props - TeachingPopoverBody properties\n * @param ref - reference to root HTMLElement of TeachingPopoverBody\n */\nexport const useTeachingPopoverBody_unstable = (\n props: TeachingPopoverBodyProps,\n ref: React.Ref<HTMLDivElement>,\n): TeachingPopoverBodyState => {\n const { mediaLength } = props;\n\n return {\n components: {\n root: 'div',\n media: 'span',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n media: slot.optional(props.media, { elementType: 'span' }),\n mediaLength: mediaLength ?? 'short',\n };\n};\n"],"names":["useTeachingPopoverBody_unstable","props","ref","mediaLength","components","root","media","slot","always","getIntrinsicElementProps","elementType","optional"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAQaA;;;eAAAA;;;;iEARU;gCACwB;AAOxC,MAAMA,kCAAkC,CAC7CC,OACAC;IAEA,MAAM,EAAEC,WAAW,EAAE,GAAGF;IAExB,OAAO;QACLG,YAAY;YACVC,MAAM;YACNC,OAAO;QACT;QACAD,MAAME,oBAAAA,CAAKC,MAAM,CACfC,IAAAA,wCAAAA,EAAyB,OAAO;YAC9BP;YACA,GAAGD,KAAK;QACV,IACA;YAAES,aAAa;QAAM;QAEvBJ,OAAOC,oBAAAA,CAAKI,QAAQ,CAACV,MAAMK,KAAK,EAAE;YAAEI,aAAa;QAAO;QACxDP,aAAaA,gBAAAA,QAAAA,gBAAAA,KAAAA,IAAAA,cAAe;IAC9B;AACF"}
@@ -0,0 +1,108 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
teachingPopoverBodyClassNames: function() {
return teachingPopoverBodyClassNames;
},
useMediaStyles: function() {
return useMediaStyles;
},
useTeachingPopoverBodyStyles_unstable: function() {
return useTeachingPopoverBodyStyles_unstable;
}
});
const _react = require("@griffel/react");
const teachingPopoverBodyClassNames = {
root: 'fui-TeachingPopoverBody',
media: 'fui-TeachingPopoverBody__media'
};
const popoverBodyDimension = 288;
const useMediaStyles = /*#__PURE__*/ (0, _react.__styles)({
base: {
Bw0ie65: 0,
Br312pm: 0,
nk6f5a: 0,
Ijaq50: 0,
Bq1tomu: "fujjg13",
B68tc82: 0,
Bmxbyg5: 0,
Bpg54ce: "f1a3p1vp",
a9b677: "f14z66ap",
jrapky: "f1jlhsmd",
ha4doy: "fmrv4ls",
Brf1p80: "f4d9j23",
mc9l5x: "f22iagw"
},
short: {
Bubjx69: "f1taewuw",
Bmuttt3: "fs5pxn9"
},
medium: {
Bubjx69: "f7da563",
Bmuttt3: "f98prui"
},
tall: {
Bubjx69: "f9ikmtg",
Bmuttt3: "fqws08j"
}
}, {
d: [
[
".fujjg13{grid-area:media;}",
{
p: -1
}
],
[
".f1a3p1vp{overflow:hidden;}",
{
p: -1
}
],
".f14z66ap{width:auto;}",
".f1jlhsmd{margin-bottom:12px;}",
".fmrv4ls{vertical-align:middle;}",
".f4d9j23{justify-content:center;}",
".f22iagw{display:flex;}",
".f1taewuw{aspect-ratio:2.4615384615384617;}",
".f7da563{aspect-ratio:1.6363636363636365;}",
".f9ikmtg{aspect-ratio:1;}"
],
t: [
"@supports not (aspect-ratio){.fs5pxn9{height:117px;}}",
"@supports not (aspect-ratio){.f98prui{height:176px;}}",
"@supports not (aspect-ratio){.fqws08j{height:288px;}}"
]
});
const useStyles = /*#__PURE__*/ (0, _react.__styles)({
root: {
mc9l5x: "f22iagw",
Beiy3e4: "f1vx9l62",
Byoj8tv: "fpe6lb7"
}
}, {
d: [
".f22iagw{display:flex;}",
".f1vx9l62{flex-direction:column;}",
".fpe6lb7{padding-bottom:12px;}"
]
});
const useTeachingPopoverBodyStyles_unstable = (state)=>{
'use no memo';
const { mediaLength } = state;
const styles = useStyles();
const mediaStyles = useMediaStyles();
state.root.className = (0, _react.mergeClasses)(teachingPopoverBodyClassNames.root, styles.root, state.root.className);
if (state.media) {
state.media.className = (0, _react.mergeClasses)(teachingPopoverBodyClassNames.media, mediaStyles.base, mediaStyles[mediaLength], state.media.className);
}
return state;
};
@@ -0,0 +1 @@
{"version":3,"sources":["useTeachingPopoverBodyStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nexport const teachingPopoverBodyClassNames = {\n root: 'fui-TeachingPopoverBody',\n media: 'fui-TeachingPopoverBody__media'\n};\nconst popoverBodyDimension = 288;\nexport const useMediaStyles = makeStyles({\n base: {\n gridArea: 'media',\n overflow: 'hidden',\n width: 'auto',\n marginBottom: '12px',\n verticalAlign: 'middle',\n justifyContent: 'center',\n display: 'flex'\n },\n short: {\n aspectRatio: popoverBodyDimension / 117,\n '@supports not (aspect-ratio)': {\n height: '117px'\n }\n },\n medium: {\n aspectRatio: popoverBodyDimension / 176,\n '@supports not (aspect-ratio)': {\n height: '176px'\n }\n },\n tall: {\n aspectRatio: 1,\n '@supports not (aspect-ratio)': {\n height: `${popoverBodyDimension}px`\n }\n }\n});\nconst useStyles = makeStyles({\n root: {\n display: 'flex',\n flexDirection: 'column',\n paddingBottom: '12px'\n }\n});\n/** Applies style classnames to slots */ export const useTeachingPopoverBodyStyles_unstable = (state)=>{\n 'use no memo';\n const { mediaLength } = state;\n const styles = useStyles();\n const mediaStyles = useMediaStyles();\n state.root.className = mergeClasses(teachingPopoverBodyClassNames.root, styles.root, state.root.className);\n if (state.media) {\n state.media.className = mergeClasses(teachingPopoverBodyClassNames.media, mediaStyles.base, mediaStyles[mediaLength], state.media.className);\n }\n return state;\n};\n"],"names":["teachingPopoverBodyClassNames","useMediaStyles","useTeachingPopoverBodyStyles_unstable","root","media","popoverBodyDimension","__styles","base","Bw0ie65","Br312pm","nk6f5a","Ijaq50","Bq1tomu","B68tc82","Bmxbyg5","Bpg54ce","a9b677","jrapky","ha4doy","Brf1p80","mc9l5x","short","Bubjx69","Bmuttt3","medium","tall","d","p","t","useStyles","Beiy3e4","Byoj8tv","state","mediaLength","styles","mediaStyles","className","mergeClasses"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IACaA,6BAA6B;eAA7BA;;IAKAC,cAAc;eAAdA;;IAoCyCC,qCAAqC;eAArCA;;;uBA1Cb;AAClC,MAAMF,gCAAgC;IACzCG,MAAM;IACNC,OAAO;AACX;AACA,MAAMC,uBAAuB;AACtB,MAAMJ,iBAAc,WAAA,GAAGK,IAAAA,eAAA,EAAA;IAAAC,MAAA;QAAAC,SAAA;QAAAC,SAAA;QAAAC,QAAA;QAAAC,QAAA;QAAAC,SAAA;QAAAC,SAAA;QAAAC,SAAA;QAAAC,SAAA;QAAAC,QAAA;QAAAC,QAAA;QAAAC,QAAA;QAAAC,SAAA;QAAAC,QAAA;IAAA;IAAAC,OAAA;QAAAC,SAAA;QAAAC,SAAA;IAAA;IAAAC,QAAA;QAAAF,SAAA;QAAAC,SAAA;IAAA;IAAAE,MAAA;QAAAH,SAAA;QAAAC,SAAA;IAAA;AAAA,GAAA;IAAAG,GAAA;QAAA;YAAA;YAAA;gBAAAC,GAAA,CAAA;YAAA;SAAA;QAAA;YAAA;YAAA;gBAAAA,GAAA,CAAA;YAAA;SAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;KAAA;IAAAC,GAAA;QAAA;QAAA;QAAA;KAAA;AAAA;AA6B9B,MAAMC,YAAS,WAAA,GAAGvB,IAAAA,eAAA,EAAA;IAAAH,MAAA;QAAAiB,QAAA;QAAAU,SAAA;QAAAC,SAAA;IAAA;AAAA,GAAA;IAAAL,GAAA;QAAA;QAAA;QAAA;KAAA;AAAA;AAO8B,MAAMxB,wCAAyC8B,CAAAA;IAC3F;IACA,MAAM,EAAEC,WAAAA,EAAa,GAAGD;IACxB,MAAME,SAASL;IACf,MAAMM,cAAclC;IACpB+B,MAAM7B,IAAI,CAACiC,SAAS,GAAGC,IAAAA,mBAAY,EAACrC,8BAA8BG,IAAI,EAAE+B,OAAO/B,IAAI,EAAE6B,MAAM7B,IAAI,CAACiC,SAAS;IACzG,IAAIJ,MAAM5B,KAAK,EAAE;QACb4B,MAAM5B,KAAK,CAACgC,SAAS,GAAGC,IAAAA,mBAAY,EAACrC,8BAA8BI,KAAK,EAAE+B,YAAY5B,IAAI,EAAE4B,WAAW,CAACF,YAAY,EAAED,MAAM5B,KAAK,CAACgC,SAAS;IAC/I;IACA,OAAOJ;AACX"}
@@ -0,0 +1,142 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useCarousel_unstable", {
enumerable: true,
get: function() {
return useCarousel_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _reactutilities = require("@fluentui/react-utilities");
const _reactsharedcontexts = require("@fluentui/react-shared-contexts");
const _constants = require("./constants");
const _useCarouselWalker = require("./useCarouselWalker");
const _createCarouselStore = require("./createCarouselStore");
function useCarousel_unstable(options) {
'use no memo';
const { announcement, onValueChange, onFinish } = options;
const { targetDocument } = (0, _reactsharedcontexts.useFluent_unstable)();
const win = targetDocument === null || targetDocument === void 0 ? void 0 : targetDocument.defaultView;
const { ref: carouselRef, walker: carouselWalker } = (0, _useCarouselWalker.useCarouselWalker_unstable)();
const [store] = _react.useState(()=>(0, _createCarouselStore.createCarouselStore)());
const [value, setValue] = (0, _reactutilities.useControllableState)({
defaultState: options.defaultValue,
state: options.value,
initialState: null
});
const rootRef = _react.useRef(null);
const { announce } = (0, _reactsharedcontexts.useAnnounce)();
if (process.env.NODE_ENV !== 'production') {
// eslint-disable-next-line react-hooks/rules-of-hooks
_react.useEffect(()=>{
if (value === null) {
// eslint-disable-next-line no-console
console.error('useCarousel: Carousel needs to have a `defaultValue` or `value` prop set. If you want to control the value, use the `value` prop.');
}
}, [
value
]);
}
_react.useEffect(()=>{
var _rootRef_current;
const allItems = (_rootRef_current = rootRef.current) === null || _rootRef_current === void 0 ? void 0 : _rootRef_current.querySelectorAll(`[${_constants.CAROUSEL_ITEM}]`);
for(let i = 0; i < allItems.length; i++){
store.addValue(allItems.item(i).getAttribute(_constants.CAROUSEL_ITEM));
}
return ()=>{
store.clear();
};
}, [
store
]);
_react.useEffect(()=>{
if (!win) {
return;
}
const config = {
attributes: true,
attributeFilter: [
_constants.CAROUSEL_ITEM
],
childList: true,
subtree: true
};
// Callback function to execute when mutations are observed
const callback = (mutationList)=>{
for (const mutation of mutationList){
for (const addedNode of Array.from(mutation.addedNodes)){
if ((0, _reactutilities.isHTMLElement)(addedNode) && addedNode.hasAttribute(_constants.CAROUSEL_ITEM)) {
const newValue = addedNode.getAttribute(_constants.CAROUSEL_ITEM);
const newNode = carouselWalker.find(newValue);
if (!(newNode === null || newNode === void 0 ? void 0 : newNode.value)) {
return;
}
const previousNode = carouselWalker.prevPage(newNode === null || newNode === void 0 ? void 0 : newNode.value);
var _previousNode_value;
store.insertValue(newValue, (_previousNode_value = previousNode === null || previousNode === void 0 ? void 0 : previousNode.value) !== null && _previousNode_value !== void 0 ? _previousNode_value : null);
}
}
for (const removedNode of Array.from(mutation.removedNodes)){
if ((0, _reactutilities.isHTMLElement)(removedNode) && (removedNode === null || removedNode === void 0 ? void 0 : removedNode.hasAttribute(_constants.CAROUSEL_ITEM))) {
const removedValue = removedNode.getAttribute(_constants.CAROUSEL_ITEM);
store.removeValue(removedValue);
}
}
}
};
// Create an observer instance linked to the callback function
const observer = new win.MutationObserver(callback);
// Start observing the target node for configured mutations
observer.observe(rootRef.current, config);
// Later, you can stop observing
return ()=>{
observer.disconnect();
};
}, [
carouselWalker,
store,
win
]);
const updateSlide = (0, _reactutilities.useEventCallback)((event, newValue)=>{
setValue(newValue);
onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(event, {
event,
type: 'click',
value: newValue
});
const announceText = announcement === null || announcement === void 0 ? void 0 : announcement(newValue);
if (announceText) {
announce(announceText, {
polite: true
});
}
});
const selectPageByDirection = (0, _reactutilities.useEventCallback)((event, direction)=>{
const active = carouselWalker.active();
if (!(active === null || active === void 0 ? void 0 : active.value)) {
return;
}
const newPage = direction === 'prev' ? carouselWalker.prevPage(active.value) : carouselWalker.nextPage(active.value);
if (newPage) {
updateSlide(event, newPage === null || newPage === void 0 ? void 0 : newPage.value);
} else {
onFinish === null || onFinish === void 0 ? void 0 : onFinish(event, {
event,
type: 'click',
value: active === null || active === void 0 ? void 0 : active.value
});
}
});
return {
carouselRef: (0, _reactutilities.useMergedRefs)(rootRef, carouselRef),
carousel: {
store,
value,
selectPageByDirection,
selectPageByValue: updateSlide
}
};
}
File diff suppressed because one or more lines are too long
@@ -0,0 +1,6 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/Carousel.types.ts"],"sourcesContent":["import * as React from 'react';\nimport { EventData, EventHandler } from '@fluentui/react-utilities';\n\nexport type CarouselStore = {\n clear: () => void;\n addValue: (value: string) => void;\n insertValue: (value: string, prev: string | null) => void;\n removeValue: (value: string) => void;\n subscribe: (listener: () => void) => () => void;\n getSnapshot: () => string[];\n};\n\nexport type CarouselItem = {\n el: HTMLElement;\n value: string | null;\n};\n\nexport type UseCarouselOptions = {\n /**\n * Localizes the string used to announce carousel page changes to screen reader users\n * Defaults to: undefined\n */\n announcement?: (newValue: string) => string;\n\n /**\n * The initial page to display in uncontrolled mode.\n */\n defaultValue?: string;\n\n /**\n * The value of the currently active page.\n */\n value?: string;\n\n /**\n * Callback to notify a page change.\n */\n onValueChange?: EventHandler<CarouselValueChangeData>;\n\n /**\n * Callback to notify when the final button step of a carousel has been activated.\n */\n onFinish?: EventHandler<CarouselValueChangeData>;\n};\n\nexport type CarouselValueChangeData = EventData<'click', React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>> & {\n /**\n * The value to be set after event has occurred.\n */\n value?: string;\n};\n"],"names":[],"rangeMappings":";;;;;","mappings":";;;;;iEAAuB"}
@@ -0,0 +1,36 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
CarouselProvider: function() {
return CarouselProvider;
},
carouselContextDefaultValue: function() {
return carouselContextDefaultValue;
},
useCarouselContext_unstable: function() {
return useCarouselContext_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _reactcontextselector = require("@fluentui/react-context-selector");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _createCarouselStore = require("./createCarouselStore");
const carouselContextDefaultValue = {
store: (0, _createCarouselStore.createCarouselStore)(),
value: null,
selectPageByDirection: ()=>{
/** noop */ },
selectPageByValue: ()=>{
/** noop */ }
};
const CarouselContext = (0, _reactcontextselector.createContext)(undefined);
const CarouselProvider = CarouselContext.Provider;
const useCarouselContext_unstable = (selector)=>(0, _reactcontextselector.useContextSelector)(CarouselContext, (ctx = carouselContextDefaultValue)=>selector(ctx));
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/CarouselContext.ts"],"sourcesContent":["import { type Context, ContextSelector, createContext, useContextSelector } from '@fluentui/react-context-selector';\nimport * as React from 'react';\n\nimport type { CarouselStore } from './Carousel.types';\nimport { createCarouselStore } from './createCarouselStore';\n\nexport type CarouselContextValue = {\n store: CarouselStore;\n value: string | null;\n selectPageByDirection: (\n event: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>,\n direction: 'next' | 'prev',\n ) => void;\n selectPageByValue: (event: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>, value: string) => void;\n};\n\nexport const carouselContextDefaultValue: CarouselContextValue = {\n store: createCarouselStore(),\n value: null,\n selectPageByDirection: () => {\n /** noop */\n },\n selectPageByValue: () => {\n /** noop */\n },\n};\n\nconst CarouselContext: Context<CarouselContextValue> = createContext<CarouselContextValue | undefined>(\n undefined,\n) as Context<CarouselContextValue>;\n\nexport const CarouselProvider = CarouselContext.Provider;\n\nexport const useCarouselContext_unstable = <T>(selector: ContextSelector<CarouselContextValue, T>): T =>\n useContextSelector(CarouselContext, (ctx = carouselContextDefaultValue) => selector(ctx));\n"],"names":["CarouselProvider","carouselContextDefaultValue","useCarouselContext_unstable","store","createCarouselStore","value","selectPageByDirection","selectPageByValue","CarouselContext","createContext","undefined","Provider","selector","useContextSelector","ctx"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IA+BaA,gBAAAA;eAAAA;;IAfAC,2BAAAA;eAAAA;;IAiBAC,2BAAAA;eAAAA;;;;sCAjCoE;iEAC1D;qCAGa;AAY7B,MAAMD,8BAAoD;IAC/DE,OAAOC,IAAAA,wCAAAA;IACPC,OAAO;IACPC,uBAAuB;IACrB,SAAS,GACX;IACAC,mBAAmB;IACjB,SAAS,GACX;AACF;AAEA,MAAMC,kBAAiDC,IAAAA,mCAAAA,EACrDC;AAGK,MAAMV,mBAAmBQ,gBAAgBG,QAAQ;AAEjD,MAAMT,8BAA8B,CAAIU,WAC7CC,IAAAA,wCAAAA,EAAmBL,iBAAiB,CAACM,MAAMb,2BAA2B,GAAKW,SAASE"}
@@ -0,0 +1,6 @@
/**
* TeachingPopoverCarousel State and Context Hooks
*/ "use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/CarouselItem/CarouselItem.types.ts"],"sourcesContent":["import { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type CarouselItemSlots = {\n /**\n * The element wrapping carousel pages and navigation.\n */\n root: NonNullable<Slot<'div'>>;\n};\n\nexport type CarouselItemProps = ComponentProps<CarouselItemSlots> & {\n /**\n * The value used to identify a page,\n * it should be unique and is necessary for pagination\n */\n value: string;\n};\n\n/**\n * TeachingPopoverCarousel State and Context Hooks\n */\nexport type CarouselItemState = ComponentState<Required<CarouselItemSlots>> & {\n visible: boolean;\n} & Pick<CarouselItemProps, 'value'>;\n"],"names":[],"rangeMappings":";;","mappings":"AAiBA;;CAEC"}
@@ -0,0 +1,19 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "CarouselItem", {
enumerable: true,
get: function() {
return CarouselItem;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useCarouselItem = require("./useCarouselItem");
const _renderCarouselItem = require("./renderCarouselItem");
const CarouselItem = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useCarouselItem.useCarouselItem_unstable)(props, ref);
return (0, _renderCarouselItem.renderCarouselItem_unstable)(state);
});
CarouselItem.displayName = 'CarouselItem';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/CarouselItem/Carouseltem.tsx"],"sourcesContent":["import * as React from 'react';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\nimport { CarouselItemProps } from './CarouselItem.types';\nimport { useCarouselItem_unstable } from './useCarouselItem';\nimport { renderCarouselItem_unstable } from './renderCarouselItem';\n\n/**\n * Define a CarouselItem, using the `useCarouselItem_unstable` and 'renderCarouselItem_unstable' hooks.\n * It has no styling opinions.\n */\nexport const CarouselItem: ForwardRefComponent<CarouselItemProps> = React.forwardRef((props, ref) => {\n const state = useCarouselItem_unstable(props, ref);\n\n return renderCarouselItem_unstable(state);\n});\n\nCarouselItem.displayName = 'CarouselItem';\n"],"names":["CarouselItem","React","forwardRef","props","ref","state","useCarouselItem_unstable","renderCarouselItem_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;","mappings":";;;;+BAWaA;;;eAAAA;;;;iEAXU;iCAIkB;oCACG;AAMrC,MAAMA,eAAAA,WAAAA,GAAuDC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IAC3F,MAAMC,QAAQC,IAAAA,yCAAAA,EAAyBH,OAAOC;IAE9C,OAAOG,IAAAA,+CAAAA,EAA4BF;AACrC;AAEAL,aAAaQ,WAAW,GAAG"}
@@ -0,0 +1,16 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderCarouselItem_unstable", {
enumerable: true,
get: function() {
return renderCarouselItem_unstable;
}
});
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
const _reactutilities = require("@fluentui/react-utilities");
const renderCarouselItem_unstable = (state)=>{
(0, _reactutilities.assertSlots)(state);
return /*#__PURE__*/ (0, _jsxruntime.jsx)(state.root, {});
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/CarouselItem/renderCarouselItem.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type { CarouselItemState, CarouselItemSlots } from './CarouselItem.types';\n\n/**\n * Render the final JSX of TeachingPopoverCarousel\n */\nexport const renderCarouselItem_unstable = (state: CarouselItemState) => {\n assertSlots<CarouselItemSlots>(state);\n\n return <state.root />;\n};\n"],"names":["renderCarouselItem_unstable","state","assertSlots","_jsx","root"],"rangeMappings":";;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;gCAE4B;AAMrB,MAAMA,8BAA8B,CAACC;IAC1CC,IAAAA,2BAAAA,EAA+BD;IAE/B,OAAA,WAAA,GAAOE,IAAAA,eAAA,EAACF,MAAMG,IAAI,EAAA,CAAA;AACpB"}
@@ -0,0 +1,39 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useCarouselItem_unstable", {
enumerable: true,
get: function() {
return useCarouselItem_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _reactutilities = require("@fluentui/react-utilities");
const _CarouselContext = require("../CarouselContext");
const _constants = require("../constants");
const useCarouselItem_unstable = (props, ref)=>{
const { value } = props;
const visible = (0, _CarouselContext.useCarouselContext_unstable)((c)=>c.value === value);
const state = {
value,
visible,
components: {
root: 'div'
},
root: _reactutilities.slot.always((0, _reactutilities.getIntrinsicElementProps)('div', {
ref,
[_constants.CAROUSEL_ITEM]: value,
[_constants.CAROUSEL_ACTIVE_ITEM]: visible,
hidden: !visible,
...props
}), {
elementType: 'div'
})
};
if (!visible) {
state.root.children = null;
}
return state;
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/CarouselItem/useCarouselItem.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';\nimport { CarouselItemProps, CarouselItemState } from './CarouselItem.types';\nimport { useCarouselContext_unstable } from '../CarouselContext';\nimport { CAROUSEL_ACTIVE_ITEM, CAROUSEL_ITEM } from '../constants';\n\nexport const useCarouselItem_unstable = (\n props: CarouselItemProps,\n ref: React.Ref<HTMLDivElement>,\n): CarouselItemState => {\n const { value } = props;\n\n const visible = useCarouselContext_unstable(c => c.value === value);\n const state: CarouselItemState = {\n value,\n visible,\n components: {\n root: 'div',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n [CAROUSEL_ITEM]: value,\n [CAROUSEL_ACTIVE_ITEM]: visible,\n hidden: !visible,\n ...props,\n }),\n { elementType: 'div' },\n ),\n };\n\n if (!visible) {\n state.root.children = null;\n }\n\n return state;\n};\n"],"names":["useCarouselItem_unstable","props","ref","value","visible","useCarouselContext_unstable","c","state","components","root","slot","always","getIntrinsicElementProps","CAROUSEL_ITEM","CAROUSEL_ACTIVE_ITEM","hidden","elementType","children"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAMaA;;;eAAAA;;;;iEANU;gCACwB;iCAEH;2BACQ;AAE7C,MAAMA,2BAA2B,CACtCC,OACAC;IAEA,MAAM,EAAEC,KAAK,EAAE,GAAGF;IAElB,MAAMG,UAAUC,IAAAA,4CAAAA,EAA4BC,CAAAA,IAAKA,EAAEH,KAAK,KAAKA;IAC7D,MAAMI,QAA2B;QAC/BJ;QACAC;QACAI,YAAY;YACVC,MAAM;QACR;QACAA,MAAMC,oBAAAA,CAAKC,MAAM,CACfC,IAAAA,wCAAAA,EAAyB,OAAO;YAC9BV;YACA,CAACW,wBAAAA,CAAc,EAAEV;YACjB,CAACW,+BAAAA,CAAqB,EAAEV;YACxBW,QAAQ,CAACX;YACT,GAAGH,KAAK;QACV,IACA;YAAEe,aAAa;QAAM;IAEzB;IAEA,IAAI,CAACZ,SAAS;QACZG,MAAME,IAAI,CAACQ,QAAQ,GAAG;IACxB;IAEA,OAAOV;AACT"}
@@ -0,0 +1,20 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
CAROUSEL_ACTIVE_ITEM: function() {
return CAROUSEL_ACTIVE_ITEM;
},
CAROUSEL_ITEM: function() {
return CAROUSEL_ITEM;
}
});
const CAROUSEL_ITEM = 'data-carousel-item';
const CAROUSEL_ACTIVE_ITEM = 'data-carousel-active-item';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/constants.ts"],"sourcesContent":["export const CAROUSEL_ITEM = 'data-carousel-item';\nexport const CAROUSEL_ACTIVE_ITEM = 'data-carousel-active-item';\n"],"names":["CAROUSEL_ACTIVE_ITEM","CAROUSEL_ITEM"],"rangeMappings":";;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IACaA,oBAAAA;eAAAA;;IADAC,aAAAA;eAAAA;;;AAAN,MAAMA,gBAAgB;AACtB,MAAMD,uBAAuB"}
@@ -0,0 +1,70 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "createCarouselStore", {
enumerable: true,
get: function() {
return createCarouselStore;
}
});
const createCarouselStore = ()=>{
let values = [];
let listeners = [];
const carouselStore = {
clear () {
values = [];
emitChange();
},
addValue (value) {
values = [
...values,
value
];
emitChange();
},
insertValue (value, prev) {
if (!prev) {
values = [
value,
...values
];
} else {
const pos = values.indexOf(prev);
values.splice(pos + 1, 0, value);
// Required to be defined as a 'new' array for useSyncExternalStore
values = [
...values
];
}
emitChange();
},
removeValue (value) {
const pos = values.indexOf(value);
values.splice(pos, 1);
// Required to be defined as a 'new' array for useSyncExternalStore
values = [
...values
];
emitChange();
},
subscribe (listener) {
listeners = [
...listeners,
listener
];
return ()=>{
listeners = listeners.filter((l)=>l !== listener);
};
},
getSnapshot () {
return values;
}
};
function emitChange() {
for (const listener of listeners){
listener();
}
}
return carouselStore;
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/createCarouselStore.ts"],"sourcesContent":["import { type CarouselStore } from './Carousel.types';\n\nexport const createCarouselStore = (): CarouselStore => {\n let values: string[] = [];\n let listeners: Array<() => void> = [];\n\n const carouselStore = {\n clear() {\n values = [];\n emitChange();\n },\n addValue(value: string) {\n values = [...values, value];\n\n emitChange();\n },\n insertValue(value: string, prev: string | null) {\n if (!prev) {\n values = [value, ...values];\n } else {\n const pos = values.indexOf(prev);\n values.splice(pos + 1, 0, value);\n // Required to be defined as a 'new' array for useSyncExternalStore\n values = [...values];\n }\n emitChange();\n },\n removeValue(value: string) {\n const pos = values.indexOf(value);\n values.splice(pos, 1);\n // Required to be defined as a 'new' array for useSyncExternalStore\n values = [...values];\n emitChange();\n },\n subscribe(listener: () => void) {\n listeners = [...listeners, listener];\n\n return () => {\n listeners = listeners.filter(l => l !== listener);\n };\n },\n getSnapshot() {\n return values;\n },\n };\n\n function emitChange() {\n for (const listener of listeners) {\n listener();\n }\n }\n\n return carouselStore;\n};\n"],"names":["createCarouselStore","values","listeners","carouselStore","clear","emitChange","addValue","value","insertValue","prev","pos","indexOf","splice","removeValue","subscribe","listener","filter","l","getSnapshot"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAEaA;;;eAAAA;;;AAAN,MAAMA,sBAAsB;IACjC,IAAIC,SAAmB,EAAE;IACzB,IAAIC,YAA+B,EAAE;IAErC,MAAMC,gBAAgB;QACpBC;YACEH,SAAS,EAAE;YACXI;QACF;QACAC,UAASC,KAAa;YACpBN,SAAS;mBAAIA;gBAAQM;aAAM;YAE3BF;QACF;QACAG,aAAYD,KAAa,EAAEE,IAAmB;YAC5C,IAAI,CAACA,MAAM;gBACTR,SAAS;oBAACM;uBAAUN;iBAAO;YAC7B,OAAO;gBACL,MAAMS,MAAMT,OAAOU,OAAO,CAACF;gBAC3BR,OAAOW,MAAM,CAACF,MAAM,GAAG,GAAGH;gBAC1B,mEAAmE;gBACnEN,SAAS;uBAAIA;iBAAO;YACtB;YACAI;QACF;QACAQ,aAAYN,KAAa;YACvB,MAAMG,MAAMT,OAAOU,OAAO,CAACJ;YAC3BN,OAAOW,MAAM,CAACF,KAAK;YACnB,mEAAmE;YACnET,SAAS;mBAAIA;aAAO;YACpBI;QACF;QACAS,WAAUC,QAAoB;YAC5Bb,YAAY;mBAAIA;gBAAWa;aAAS;YAEpC,OAAO;gBACLb,YAAYA,UAAUc,MAAM,CAACC,CAAAA,IAAKA,MAAMF;YAC1C;QACF;QACAG;YACE,OAAOjB;QACT;IACF;IAEA,SAASI;QACP,KAAK,MAAMU,YAAYb,UAAW;YAChCa;QACF;IACF;IAEA,OAAOZ;AACT"}
@@ -0,0 +1,16 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useCarouselValues_unstable", {
enumerable: true,
get: function() {
return useCarouselValues_unstable;
}
});
const _shim = require("use-sync-external-store/shim");
const _CarouselContext = require("./CarouselContext");
function useCarouselValues_unstable(getSnapshot) {
const store = (0, _CarouselContext.useCarouselContext_unstable)((c)=>c.store);
return (0, _shim.useSyncExternalStore)(store.subscribe, ()=>getSnapshot(store.getSnapshot()));
}
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/Carousel/useCarouselValues.ts"],"sourcesContent":["import { useSyncExternalStore } from 'use-sync-external-store/shim';\n\nimport { useCarouselContext_unstable } from './CarouselContext';\nimport type { CarouselStore } from './Carousel.types';\n\nexport function useCarouselValues_unstable<T>(getSnapshot: (values: ReturnType<CarouselStore['getSnapshot']>) => T): T {\n const store = useCarouselContext_unstable(c => c.store);\n\n return useSyncExternalStore(store.subscribe, () => getSnapshot(store.getSnapshot()));\n}\n"],"names":["useCarouselValues_unstable","getSnapshot","store","useCarouselContext_unstable","c","useSyncExternalStore","subscribe"],"rangeMappings":";;;;;;;;;;;;;;;","mappings":";;;;+BAKgBA;;;eAAAA;;;sBALqB;iCAEO;AAGrC,SAASA,2BAA8BC,WAAoE;IAChH,MAAMC,QAAQC,IAAAA,4CAAAA,EAA4BC,CAAAA,IAAKA,EAAEF,KAAK;IAEtD,OAAOG,IAAAA,0BAAAA,EAAqBH,MAAMI,SAAS,EAAE,IAAML,YAAYC,MAAMD,WAAW;AAClF"}
@@ -0,0 +1,109 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useCarouselWalker_unstable", {
enumerable: true,
get: function() {
return useCarouselWalker_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _reactutilities = require("@fluentui/react-utilities");
const _reactsharedcontexts = require("@fluentui/react-shared-contexts");
const _constants = require("./constants");
const useCarouselWalker_unstable = ()=>{
const { targetDocument } = (0, _reactsharedcontexts.useFluent_unstable)();
const treeWalkerRef = _react.useRef(targetDocument === null || targetDocument === void 0 ? void 0 : targetDocument.createTreeWalker(targetDocument.body));
const htmlRef = _react.useRef(null);
const ref = _react.useCallback((el)=>{
if (!targetDocument) {
return;
}
if (!el) {
return;
}
htmlRef.current = el;
treeWalkerRef.current = targetDocument.createTreeWalker(el, NodeFilter.SHOW_ELEMENT, {
acceptNode (node) {
if (!(0, _reactutilities.isHTMLElement)(node)) {
return NodeFilter.FILTER_SKIP;
}
return node.hasAttribute(_constants.CAROUSEL_ITEM) ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
}
});
}, [
targetDocument
]);
return {
ref,
walker: _react.useMemo(()=>({
active () {
if (!htmlRef.current) {
return null;
}
const activeEl = htmlRef.current.querySelector(`[${_constants.CAROUSEL_ACTIVE_ITEM}="true"]`);
if ((0, _reactutilities.isHTMLElement)(activeEl)) {
return {
el: activeEl,
value: activeEl.getAttribute(_constants.CAROUSEL_ITEM)
};
}
return null;
},
find (value) {
var _treeWalkerRef_current;
if (!((_treeWalkerRef_current = treeWalkerRef.current) === null || _treeWalkerRef_current === void 0 ? void 0 : _treeWalkerRef_current.currentNode) || !htmlRef.current) {
return null;
}
treeWalkerRef.current.currentNode = htmlRef.current;
let nextNode = null;
while(nextNode = treeWalkerRef.current.nextNode()){
if (!(0, _reactutilities.isHTMLElement)(nextNode)) {
continue;
}
if (nextNode.getAttribute(_constants.CAROUSEL_ITEM) === value) {
return {
el: nextNode,
value: nextNode.getAttribute(_constants.CAROUSEL_ITEM)
};
}
}
return null;
},
nextPage (value) {
var _treeWalkerRef_current;
const res = this.find(value);
if (!res || !((_treeWalkerRef_current = treeWalkerRef.current) === null || _treeWalkerRef_current === void 0 ? void 0 : _treeWalkerRef_current.currentNode)) {
return null;
}
treeWalkerRef.current.currentNode = res.el;
const next = treeWalkerRef.current.nextNode();
if ((0, _reactutilities.isHTMLElement)(next)) {
return {
el: next,
value: next.getAttribute(_constants.CAROUSEL_ITEM)
};
}
return null;
},
prevPage (value) {
var _treeWalkerRef_current;
const res = this.find(value);
if (!res || !((_treeWalkerRef_current = treeWalkerRef.current) === null || _treeWalkerRef_current === void 0 ? void 0 : _treeWalkerRef_current.currentNode)) {
return null;
}
treeWalkerRef.current.currentNode = res.el;
const next = treeWalkerRef.current.previousNode();
if ((0, _reactutilities.isHTMLElement)(next)) {
return {
el: next,
value: next.getAttribute(_constants.CAROUSEL_ITEM)
};
}
return null;
}
}), [])
};
};
File diff suppressed because one or more lines are too long
@@ -0,0 +1,25 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "TeachingPopoverCarousel", {
enumerable: true,
get: function() {
return TeachingPopoverCarousel;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useTeachingPopoverCarousel = require("./useTeachingPopoverCarousel");
const _renderTeachingPopoverCarousel = require("./renderTeachingPopoverCarousel");
const _useTeachingPopoverCarouselStylesstyles = require("./useTeachingPopoverCarouselStyles.styles");
const _reactsharedcontexts = require("@fluentui/react-shared-contexts");
const _useTeachingPopoverCarouselContextValues = require("./useTeachingPopoverCarouselContextValues");
const TeachingPopoverCarousel = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useTeachingPopoverCarousel.useTeachingPopoverCarousel_unstable)(props, ref);
(0, _useTeachingPopoverCarouselStylesstyles.useTeachingPopoverCarouselStyles_unstable)(state);
(0, _reactsharedcontexts.useCustomStyleHook_unstable)('useTeachingPopoverCarouselStyles_unstable')(state);
const contextValues = (0, _useTeachingPopoverCarouselContextValues.useTeachingPopoverCarouselContextValues_unstable)(state);
return (0, _renderTeachingPopoverCarousel.renderTeachingPopoverCarousel_unstable)(state, contextValues);
});
TeachingPopoverCarousel.displayName = 'TeachingPopoverCarousel';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/TeachingPopoverCarousel.tsx"],"sourcesContent":["import * as React from 'react';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\nimport { useTeachingPopoverCarousel_unstable } from './useTeachingPopoverCarousel';\nimport { renderTeachingPopoverCarousel_unstable } from './renderTeachingPopoverCarousel';\nimport { useTeachingPopoverCarouselStyles_unstable } from './useTeachingPopoverCarouselStyles.styles';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\nimport type { TeachingPopoverCarouselProps } from './TeachingPopoverCarousel.types';\nimport { useTeachingPopoverCarouselContextValues_unstable } from './useTeachingPopoverCarouselContextValues';\n\n/**\n * Define a styled TeachingPopoverCarousel, using the `useTeachingPopoverCarousel_unstable` and `useTeachingPopoverCarouselStyles_unstable`\n * hooks.\n *\n * TeachingPopoverCarousel injects context providers that are required for TeachingPopoverCarouselCard display and navigation functionality\n */\nexport const TeachingPopoverCarousel: ForwardRefComponent<TeachingPopoverCarouselProps> = React.forwardRef(\n (props, ref) => {\n const state = useTeachingPopoverCarousel_unstable(props, ref);\n\n useTeachingPopoverCarouselStyles_unstable(state);\n\n useCustomStyleHook_unstable('useTeachingPopoverCarouselStyles_unstable')(state);\n\n const contextValues = useTeachingPopoverCarouselContextValues_unstable(state);\n\n return renderTeachingPopoverCarousel_unstable(state, contextValues);\n },\n);\n\nTeachingPopoverCarousel.displayName = 'TeachingPopoverCarousel';\n"],"names":["TeachingPopoverCarousel","React","forwardRef","props","ref","state","useTeachingPopoverCarousel_unstable","useTeachingPopoverCarouselStyles_unstable","useCustomStyleHook_unstable","contextValues","useTeachingPopoverCarouselContextValues_unstable","renderTeachingPopoverCarousel_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAgBaA;;;eAAAA;;;;iEAhBU;4CAG6B;+CACG;wDACG;qCACd;yDAEqB;AAQ1D,MAAMA,0BAAAA,WAAAA,GAA6EC,OAAMC,UAAU,CACxG,CAACC,OAAOC;IACN,MAAMC,QAAQC,IAAAA,+DAAAA,EAAoCH,OAAOC;IAEzDG,IAAAA,iFAAAA,EAA0CF;IAE1CG,IAAAA,gDAAAA,EAA4B,6CAA6CH;IAEzE,MAAMI,gBAAgBC,IAAAA,yFAAAA,EAAiDL;IAEvE,OAAOM,IAAAA,qEAAAA,EAAuCN,OAAOI;AACvD;AAGFT,wBAAwBY,WAAW,GAAG"}
@@ -0,0 +1,6 @@
/**
* Context shared between TeachingPopoverCarousel and its children components
*/ "use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/TeachingPopoverCarousel.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport { type PopoverContextValue } from '@fluentui/react-popover';\n\nimport { type CarouselContextValue } from './Carousel/CarouselContext';\nimport type { UseCarouselOptions } from './Carousel/Carousel.types';\n\nexport type TeachingPopoverCarouselSlots = {\n /**\n * The element wrapping carousel pages and navigation.\n */\n root: NonNullable<Slot<'div'>>;\n};\n\n/**\n * TeachingPopoverCarousel Props\n */\nexport type TeachingPopoverCarouselProps = ComponentProps<TeachingPopoverCarouselSlots> & UseCarouselOptions;\n\n/**\n * TeachingPopoverCarousel State and Context Hooks\n */\nexport type TeachingPopoverCarouselState = ComponentState<Required<TeachingPopoverCarouselSlots>> &\n Partial<Pick<PopoverContextValue, 'appearance'>> &\n CarouselContextValue;\n\n/**\n * Context shared between TeachingPopoverCarousel and its children components\n */\nexport type TeachingPopoverCarouselContextValues = {\n carousel: CarouselContextValue;\n};\n"],"names":[],"rangeMappings":";;","mappings":"AAyBA;;CAEC"}
@@ -0,0 +1,35 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
TeachingPopoverCarousel: function() {
return _TeachingPopoverCarousel.TeachingPopoverCarousel;
},
renderTeachingPopoverCarousel_unstable: function() {
return _renderTeachingPopoverCarousel.renderTeachingPopoverCarousel_unstable;
},
teachingPopoverCarouselClassNames: function() {
return _useTeachingPopoverCarouselStylesstyles.teachingPopoverCarouselClassNames;
},
useTeachingPopoverCarouselContextValues_unstable: function() {
return _useTeachingPopoverCarouselContextValues.useTeachingPopoverCarouselContextValues_unstable;
},
useTeachingPopoverCarouselStyles_unstable: function() {
return _useTeachingPopoverCarouselStylesstyles.useTeachingPopoverCarouselStyles_unstable;
},
useTeachingPopoverCarousel_unstable: function() {
return _useTeachingPopoverCarousel.useTeachingPopoverCarousel_unstable;
}
});
const _TeachingPopoverCarousel = require("./TeachingPopoverCarousel");
const _renderTeachingPopoverCarousel = require("./renderTeachingPopoverCarousel");
const _useTeachingPopoverCarousel = require("./useTeachingPopoverCarousel");
const _useTeachingPopoverCarouselStylesstyles = require("./useTeachingPopoverCarouselStyles.styles");
const _useTeachingPopoverCarouselContextValues = require("./useTeachingPopoverCarouselContextValues");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/index.ts"],"sourcesContent":["export { TeachingPopoverCarousel } from './TeachingPopoverCarousel';\nexport type {\n TeachingPopoverCarouselContextValues,\n TeachingPopoverCarouselProps,\n TeachingPopoverCarouselSlots,\n TeachingPopoverCarouselState,\n} from './TeachingPopoverCarousel.types';\nexport { renderTeachingPopoverCarousel_unstable } from './renderTeachingPopoverCarousel';\nexport { useTeachingPopoverCarousel_unstable } from './useTeachingPopoverCarousel';\nexport {\n teachingPopoverCarouselClassNames,\n useTeachingPopoverCarouselStyles_unstable,\n} from './useTeachingPopoverCarouselStyles.styles';\nexport { useTeachingPopoverCarouselContextValues_unstable } from './useTeachingPopoverCarouselContextValues';\n"],"names":["TeachingPopoverCarousel","renderTeachingPopoverCarousel_unstable","teachingPopoverCarouselClassNames","useTeachingPopoverCarouselContextValues_unstable","useTeachingPopoverCarouselStyles_unstable","useTeachingPopoverCarousel_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,uBAAuB;eAAvBA,gDAAuB;;IAOvBC,sCAAsC;eAAtCA,qEAAsC;;IAG7CC,iCAAiC;eAAjCA,yEAAiC;;IAG1BC,gDAAgD;eAAhDA,yFAAgD;;IAFvDC,yCAAyC;eAAzCA,iFAAyC;;IAHlCC,mCAAmC;eAAnCA,+DAAmC;;;yCARJ;+CAOe;4CACH;wDAI7C;yDAC0D"}
@@ -0,0 +1,20 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderTeachingPopoverCarousel_unstable", {
enumerable: true,
get: function() {
return renderTeachingPopoverCarousel_unstable;
}
});
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
const _reactutilities = require("@fluentui/react-utilities");
const _CarouselContext = require("./Carousel/CarouselContext");
const renderTeachingPopoverCarousel_unstable = (state, contextValues)=>{
(0, _reactutilities.assertSlots)(state);
return /*#__PURE__*/ (0, _jsxruntime.jsx)(_CarouselContext.CarouselProvider, {
value: contextValues.carousel,
children: /*#__PURE__*/ (0, _jsxruntime.jsx)(state.root, {})
});
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/renderTeachingPopoverCarousel.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type {\n TeachingPopoverCarouselState,\n TeachingPopoverCarouselSlots,\n TeachingPopoverCarouselContextValues,\n} from './TeachingPopoverCarousel.types';\nimport { CarouselProvider } from './Carousel/CarouselContext';\n\n/**\n * Render the final JSX of TeachingPopoverCarousel\n */\nexport const renderTeachingPopoverCarousel_unstable = (\n state: TeachingPopoverCarouselState,\n contextValues: TeachingPopoverCarouselContextValues,\n) => {\n assertSlots<TeachingPopoverCarouselSlots>(state);\n\n return (\n <CarouselProvider value={contextValues.carousel}>\n <state.root />\n </CarouselProvider>\n );\n};\n"],"names":["renderTeachingPopoverCarousel_unstable","state","contextValues","assertSlots","_jsx","CarouselProvider","value","carousel","root"],"rangeMappings":";;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAcaA;;;eAAAA;;;4BAbb;gCAE4B;iCAMK;AAK1B,MAAMA,yCAAyC,CACpDC,OACAC;IAEAC,IAAAA,2BAAAA,EAA0CF;IAE1C,OAAA,WAAA,GACEG,IAAAA,eAAA,EAACC,iCAAAA,EAAAA;QAAiBC,OAAOJ,cAAcK,QAAQ;kBAC7C,WAAA,GAAAH,IAAAA,eAAA,EAACH,MAAMO,IAAI,EAAA,CAAA;;AAGjB"}
@@ -0,0 +1,44 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useTeachingPopoverCarousel_unstable", {
enumerable: true,
get: function() {
return useTeachingPopoverCarousel_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _reactutilities = require("@fluentui/react-utilities");
const _reactpopover = require("@fluentui/react-popover");
const _Carousel = require("./Carousel/Carousel");
const useTeachingPopoverCarousel_unstable = (props, ref)=>{
const toggleOpen = (0, _reactpopover.usePopoverContext_unstable)((c)=>c.toggleOpen);
const handleFinish = (0, _reactutilities.useEventCallback)((event, data)=>{
var _props_onFinish;
(_props_onFinish = props.onFinish) === null || _props_onFinish === void 0 ? void 0 : _props_onFinish.call(props, event, data);
toggleOpen(event);
});
const { carousel, carouselRef } = (0, _Carousel.useCarousel_unstable)({
announcement: props.announcement,
defaultValue: props.defaultValue,
value: props.value,
onValueChange: props.onValueChange,
onFinish: handleFinish
});
const appearance = (0, _reactpopover.usePopoverContext_unstable)((context)=>context.appearance);
return {
appearance,
components: {
root: 'div'
},
root: _reactutilities.slot.always((0, _reactutilities.getIntrinsicElementProps)('div', {
ref: (0, _reactutilities.useMergedRefs)(ref, carouselRef),
...props
}), {
elementType: 'div'
}),
...carousel
};
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/useTeachingPopoverCarousel.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, slot, useEventCallback, useMergedRefs } from '@fluentui/react-utilities';\nimport type { TeachingPopoverCarouselProps, TeachingPopoverCarouselState } from './TeachingPopoverCarousel.types';\nimport { usePopoverContext_unstable } from '@fluentui/react-popover';\nimport { useCarousel_unstable } from './Carousel/Carousel';\n\nexport const useTeachingPopoverCarousel_unstable = (\n props: TeachingPopoverCarouselProps,\n ref: React.Ref<HTMLDivElement>,\n): TeachingPopoverCarouselState => {\n const toggleOpen = usePopoverContext_unstable(c => c.toggleOpen);\n const handleFinish: TeachingPopoverCarouselProps['onFinish'] = useEventCallback((event, data) => {\n props.onFinish?.(event, data);\n toggleOpen(event as React.MouseEvent<HTMLElement>);\n });\n\n const { carousel, carouselRef } = useCarousel_unstable({\n announcement: props.announcement,\n defaultValue: props.defaultValue,\n value: props.value,\n onValueChange: props.onValueChange,\n onFinish: handleFinish,\n });\n\n const appearance = usePopoverContext_unstable(context => context.appearance);\n return {\n appearance,\n components: {\n root: 'div',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref: useMergedRefs(ref, carouselRef),\n ...props,\n }),\n { elementType: 'div' },\n ),\n ...carousel,\n };\n};\n"],"names":["useTeachingPopoverCarousel_unstable","props","ref","toggleOpen","usePopoverContext_unstable","c","handleFinish","useEventCallback","event","data","onFinish","carousel","carouselRef","useCarousel_unstable","announcement","defaultValue","value","onValueChange","appearance","context","components","root","slot","always","getIntrinsicElementProps","useMergedRefs","elementType"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAMaA;;;eAAAA;;;;iEANU;gCACyD;8BAErC;0BACN;AAE9B,MAAMA,sCAAsC,CACjDC,OACAC;IAEA,MAAMC,aAAaC,IAAAA,wCAAAA,EAA2BC,CAAAA,IAAKA,EAAEF,UAAU;IAC/D,MAAMG,eAAyDC,IAAAA,gCAAAA,EAAiB,CAACC,OAAOC;YACtFR;QAAAA,CAAAA,kBAAAA,MAAMS,QAAQ,AAARA,MAAQ,QAAdT,oBAAAA,KAAAA,IAAAA,KAAAA,IAAAA,gBAAAA,IAAAA,CAAAA,OAAiBO,OAAOC;QACxBN,WAAWK;IACb;IAEA,MAAM,EAAEG,QAAQ,EAAEC,WAAW,EAAE,GAAGC,IAAAA,8BAAAA,EAAqB;QACrDC,cAAcb,MAAMa,YAAY;QAChCC,cAAcd,MAAMc,YAAY;QAChCC,OAAOf,MAAMe,KAAK;QAClBC,eAAehB,MAAMgB,aAAa;QAClCP,UAAUJ;IACZ;IAEA,MAAMY,aAAad,IAAAA,wCAAAA,EAA2Be,CAAAA,UAAWA,QAAQD,UAAU;IAC3E,OAAO;QACLA;QACAE,YAAY;YACVC,MAAM;QACR;QACAA,MAAMC,oBAAAA,CAAKC,MAAM,CACfC,IAAAA,wCAAAA,EAAyB,OAAO;YAC9BtB,KAAKuB,IAAAA,6BAAAA,EAAcvB,KAAKU;YACxB,GAAGX,KAAK;QACV,IACA;YAAEyB,aAAa;QAAM;QAEvB,GAAGf,QAAQ;IACb;AACF"}
@@ -0,0 +1,22 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useTeachingPopoverCarouselContextValues_unstable", {
enumerable: true,
get: function() {
return useTeachingPopoverCarouselContextValues_unstable;
}
});
function useTeachingPopoverCarouselContextValues_unstable(state) {
const { store, value, selectPageByValue, selectPageByDirection } = state;
const carousel = {
store,
value,
selectPageByDirection,
selectPageByValue
};
return {
carousel
};
}
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarousel/useTeachingPopoverCarouselContextValues.ts"],"sourcesContent":["import type {\n TeachingPopoverCarouselContextValues,\n TeachingPopoverCarouselState,\n} from './TeachingPopoverCarousel.types';\n\nexport function useTeachingPopoverCarouselContextValues_unstable(\n state: TeachingPopoverCarouselState,\n): TeachingPopoverCarouselContextValues {\n const { store, value, selectPageByValue, selectPageByDirection } = state;\n\n const carousel = {\n store,\n value,\n selectPageByDirection,\n selectPageByValue,\n };\n\n return { carousel };\n}\n"],"names":["useTeachingPopoverCarouselContextValues_unstable","state","store","value","selectPageByValue","selectPageByDirection","carousel"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAKgBA;;;eAAAA;;;AAAT,SAASA,iDACdC,KAAmC;IAEnC,MAAM,EAAEC,KAAK,EAAEC,KAAK,EAAEC,iBAAiB,EAAEC,qBAAqB,EAAE,GAAGJ;IAEnE,MAAMK,WAAW;QACfJ;QACAC;QACAE;QACAD;IACF;IAEA,OAAO;QAAEE;IAAS;AACpB"}
@@ -0,0 +1,32 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
teachingPopoverCarouselClassNames: function() {
return teachingPopoverCarouselClassNames;
},
useTeachingPopoverCarouselStyles_unstable: function() {
return useTeachingPopoverCarouselStyles_unstable;
}
});
const _react = require("@griffel/react");
const teachingPopoverCarouselClassNames = {
root: 'fui-TeachingPopoverCarousel'
};
// Todo: Page change animation & styles
const useStyles = /*#__PURE__*/ (0, _react.__styles)({
root: {}
}, {});
const useTeachingPopoverCarouselStyles_unstable = (state)=>{
'use no memo';
const styles = useStyles();
state.root.className = (0, _react.mergeClasses)(teachingPopoverCarouselClassNames.root, styles.root, state.root.className);
return state;
};
@@ -0,0 +1 @@
{"version":3,"sources":["useTeachingPopoverCarouselStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nexport const teachingPopoverCarouselClassNames = {\n root: 'fui-TeachingPopoverCarousel'\n};\n// Todo: Page change animation & styles\nconst useStyles = makeStyles({\n root: {}\n});\n/** Applies style classnames to slots */ export const useTeachingPopoverCarouselStyles_unstable = (state)=>{\n 'use no memo';\n const styles = useStyles();\n state.root.className = mergeClasses(teachingPopoverCarouselClassNames.root, styles.root, state.root.className);\n return state;\n};\n"],"names":["teachingPopoverCarouselClassNames","useTeachingPopoverCarouselStyles_unstable","root","useStyles","__styles","state","styles","className","mergeClasses"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IACaA,iCAAiC;eAAjCA;;IAOyCC,yCAAyC;eAAzCA;;;uBARb;AAClC,MAAMD,oCAAoC;IAC7CE,MAAM;AACV;AACA,uCAAA;AACA,MAAMC,YAAS,WAAA,GAAGC,IAAAA,eAAA,EAAA;IAAAF,MAAA,CAAA;AAAA,GAAA,CAAA;AAG8B,MAAMD,4CAA6CI,CAAAA;IAC/F;IACA,MAAMC,SAASH;IACfE,MAAMH,IAAI,CAACK,SAAS,GAAGC,IAAAA,mBAAY,EAACR,kCAAkCE,IAAI,EAAEI,OAAOJ,IAAI,EAAEG,MAAMH,IAAI,CAACK,SAAS;IAC7G,OAAOF;AACX"}
@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "TeachingPopoverCarouselCard", {
enumerable: true,
get: function() {
return TeachingPopoverCarouselCard;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useTeachingPopoverCarouselCard = require("./useTeachingPopoverCarouselCard");
const _renderTeachingPopoverCarouselCard = require("./renderTeachingPopoverCarouselCard");
const _useTeachingPopoverCarouselCardStylesstyles = require("./useTeachingPopoverCarouselCardStyles.styles");
const TeachingPopoverCarouselCard = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useTeachingPopoverCarouselCard.useTeachingPopoverCarouselCard_unstable)(props, ref);
(0, _useTeachingPopoverCarouselCardStylesstyles.useTeachingPopoverCarouselCardStyles_unstable)(state);
return (0, _renderTeachingPopoverCarouselCard.renderTeachingPopoverCarouselCard_unstable)(state);
});
TeachingPopoverCarouselCard.displayName = 'TeachingPopoverCarouselCard';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useTeachingPopoverCarouselCard_unstable } from './useTeachingPopoverCarouselCard';\nimport { renderTeachingPopoverCarouselCard_unstable } from './renderTeachingPopoverCarouselCard';\nimport type { TeachingPopoverCarouselCardProps } from './TeachingPopoverCarouselCard.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useTeachingPopoverCarouselCardStyles_unstable } from './useTeachingPopoverCarouselCardStyles.styles';\n\n/**\n * Define a styled TeachingPopoverCarouselCard, using the `useTeachingPopoverCarouselCard_unstable` and `useTeachingPopoverCarouselCardStyles_unstable`\n * hooks.\n *\n * TeachingPopoverCarouselCard is the definition of a single page view within the carousel, they are shown one at a time and can be navigated through sequentially.\n */\nexport const TeachingPopoverCarouselCard: ForwardRefComponent<TeachingPopoverCarouselCardProps> = React.forwardRef(\n (props, ref) => {\n const state = useTeachingPopoverCarouselCard_unstable(props, ref);\n\n useTeachingPopoverCarouselCardStyles_unstable(state);\n\n return renderTeachingPopoverCarouselCard_unstable(state);\n },\n);\n\nTeachingPopoverCarouselCard.displayName = 'TeachingPopoverCarouselCard';\n"],"names":["TeachingPopoverCarouselCard","React","forwardRef","props","ref","state","useTeachingPopoverCarouselCard_unstable","useTeachingPopoverCarouselCardStyles_unstable","renderTeachingPopoverCarouselCard_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAaaA;;;eAAAA;;;;iEAbU;gDACiC;mDACG;4DAGG;AAQvD,MAAMA,8BAAAA,WAAAA,GAAqFC,OAAMC,UAAU,CAChH,CAACC,OAAOC;IACN,MAAMC,QAAQC,IAAAA,uEAAAA,EAAwCH,OAAOC;IAE7DG,IAAAA,yFAAAA,EAA8CF;IAE9C,OAAOG,IAAAA,6EAAAA,EAA2CH;AACpD;AAGFL,4BAA4BS,WAAW,GAAG"}
@@ -0,0 +1,4 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselCard/TeachingPopoverCarouselCard.types.ts"],"sourcesContent":["import { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport { CarouselItemProps } from '../TeachingPopoverCarousel/Carousel/CarouselItem/CarouselItem.types';\n\nexport type TeachingPopoverCarouselCardSlots = {\n /**\n * The element wrapping the buttons.\n */\n root: NonNullable<Slot<CarouselItemProps>>;\n};\n\nexport type TeachingPopoverCarouselCardProps = ComponentProps<TeachingPopoverCarouselCardSlots> & {\n /* Required: Passed into CarouselItem to identify pages. */\n value: string;\n};\n\nexport type TeachingPopoverCarouselCardState = ComponentState<TeachingPopoverCarouselCardSlots> &\n Required<Pick<TeachingPopoverCarouselCardProps, 'value'>>;\n"],"names":[],"rangeMappings":"","mappings":""}
@@ -0,0 +1,31 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
TeachingPopoverCarouselCard: function() {
return _TeachingPopoverCarouselCard.TeachingPopoverCarouselCard;
},
renderTeachingPopoverCarouselCard_unstable: function() {
return _renderTeachingPopoverCarouselCard.renderTeachingPopoverCarouselCard_unstable;
},
teachingPopoverCarouselCardClassNames: function() {
return _useTeachingPopoverCarouselCardStylesstyles.teachingPopoverCarouselCardClassNames;
},
useTeachingPopoverCarouselCardStyles_unstable: function() {
return _useTeachingPopoverCarouselCardStylesstyles.useTeachingPopoverCarouselCardStyles_unstable;
},
useTeachingPopoverCarouselCard_unstable: function() {
return _useTeachingPopoverCarouselCard.useTeachingPopoverCarouselCard_unstable;
}
});
const _TeachingPopoverCarouselCard = require("./TeachingPopoverCarouselCard");
const _renderTeachingPopoverCarouselCard = require("./renderTeachingPopoverCarouselCard");
const _useTeachingPopoverCarouselCard = require("./useTeachingPopoverCarouselCard");
const _useTeachingPopoverCarouselCardStylesstyles = require("./useTeachingPopoverCarouselCardStyles.styles");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselCard/index.ts"],"sourcesContent":["export { TeachingPopoverCarouselCard } from './TeachingPopoverCarouselCard';\nexport type {\n TeachingPopoverCarouselCardProps,\n TeachingPopoverCarouselCardSlots,\n TeachingPopoverCarouselCardState,\n} from './TeachingPopoverCarouselCard.types';\nexport { renderTeachingPopoverCarouselCard_unstable } from './renderTeachingPopoverCarouselCard';\nexport { useTeachingPopoverCarouselCard_unstable } from './useTeachingPopoverCarouselCard';\nexport {\n teachingPopoverCarouselCardClassNames,\n useTeachingPopoverCarouselCardStyles_unstable,\n} from './useTeachingPopoverCarouselCardStyles.styles';\n"],"names":["TeachingPopoverCarouselCard","renderTeachingPopoverCarouselCard_unstable","teachingPopoverCarouselCardClassNames","useTeachingPopoverCarouselCardStyles_unstable","useTeachingPopoverCarouselCard_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,2BAA2B;eAA3BA,wDAA2B;;IAM3BC,0CAA0C;eAA1CA,6EAA0C;;IAGjDC,qCAAqC;eAArCA,iFAAqC;;IACrCC,6CAA6C;eAA7CA,yFAA6C;;IAHtCC,uCAAuC;eAAvCA,uEAAuC;;;6CAPJ;mDAMe;gDACH;4DAIjD"}
@@ -0,0 +1,16 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderTeachingPopoverCarouselCard_unstable", {
enumerable: true,
get: function() {
return renderTeachingPopoverCarouselCard_unstable;
}
});
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
const _reactutilities = require("@fluentui/react-utilities");
const renderTeachingPopoverCarouselCard_unstable = (state)=>{
(0, _reactutilities.assertSlots)(state);
return /*#__PURE__*/ (0, _jsxruntime.jsx)(state.root, {});
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselCard/renderTeachingPopoverCarouselCard.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\nimport type { TeachingPopoverCarouselCardState } from './TeachingPopoverCarouselCard.types';\nimport { TeachingPopoverCarouselCardSlots } from './TeachingPopoverCarouselCard.types';\nimport { assertSlots } from '@fluentui/react-utilities';\n\n/**\n * Render the final JSX of TeachingPopoverCarouselCard\n */\nexport const renderTeachingPopoverCarouselCard_unstable = (state: TeachingPopoverCarouselCardState) => {\n assertSlots<TeachingPopoverCarouselCardSlots>(state);\n\n return <state.root />;\n};\n"],"names":["renderTeachingPopoverCarouselCard_unstable","state","assertSlots","_jsx","root"],"rangeMappings":";;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;gCAG4B;AAKrB,MAAMA,6CAA6C,CAACC;IACzDC,IAAAA,2BAAAA,EAA8CD;IAE9C,OAAA,WAAA,GAAOE,IAAAA,eAAA,EAACF,MAAMG,IAAI,EAAA,CAAA;AACpB"}
@@ -0,0 +1,32 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useTeachingPopoverCarouselCard_unstable", {
enumerable: true,
get: function() {
return useTeachingPopoverCarouselCard_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _reactutilities = require("@fluentui/react-utilities");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _Carouseltem = require("../TeachingPopoverCarousel/Carousel/CarouselItem/Carouseltem");
const useTeachingPopoverCarouselCard_unstable = (props, ref)=>{
const { value } = props;
return {
value,
components: {
root: _Carouseltem.CarouselItem
},
root: _reactutilities.slot.always({
...(0, _reactutilities.getIntrinsicElementProps)('div', {
ref,
...props
}),
value
}, {
elementType: _Carouseltem.CarouselItem
})
};
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselCard/useTeachingPopoverCarouselCard.ts"],"sourcesContent":["import { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';\nimport * as React from 'react';\n\nimport type {\n TeachingPopoverCarouselCardProps,\n TeachingPopoverCarouselCardState,\n} from './TeachingPopoverCarouselCard.types';\nimport { CarouselItem } from '../TeachingPopoverCarousel/Carousel/CarouselItem/Carouseltem';\n\n/**\n * Returns the props and state required to render the component\n * @param props - TeachingPopoverCarouselCard properties\n * @param ref - reference to root HTMLElement of TeachingPopoverCarouselCard\n */\nexport const useTeachingPopoverCarouselCard_unstable = (\n props: TeachingPopoverCarouselCardProps,\n ref: React.Ref<HTMLDivElement>,\n): TeachingPopoverCarouselCardState => {\n const { value } = props;\n\n return {\n value,\n components: {\n root: CarouselItem,\n },\n root: slot.always(\n {\n ...getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n value,\n },\n { elementType: CarouselItem },\n ),\n };\n};\n"],"names":["useTeachingPopoverCarouselCard_unstable","props","ref","value","components","root","CarouselItem","slot","always","getIntrinsicElementProps","elementType"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAcaA;;;eAAAA;;;;gCAdkC;iEACxB;6BAMM;AAOtB,MAAMA,0CAA0C,CACrDC,OACAC;IAEA,MAAM,EAAEC,KAAK,EAAE,GAAGF;IAElB,OAAO;QACLE;QACAC,YAAY;YACVC,MAAMC,yBAAAA;QACR;QACAD,MAAME,oBAAAA,CAAKC,MAAM,CACf;YACE,GAAGC,IAAAA,wCAAAA,EAAyB,OAAO;gBACjCP;gBACA,GAAGD,KAAK;YACV,EAAE;YACFE;QACF,GACA;YAAEO,aAAaJ,yBAAAA;QAAa;IAEhC;AACF"}
@@ -0,0 +1,31 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
teachingPopoverCarouselCardClassNames: function() {
return teachingPopoverCarouselCardClassNames;
},
useTeachingPopoverCarouselCardStyles_unstable: function() {
return useTeachingPopoverCarouselCardStyles_unstable;
}
});
const _react = require("@griffel/react");
const teachingPopoverCarouselCardClassNames = {
root: 'fui-TeachingPopoverCarouselCard'
};
const useStyles = /*#__PURE__*/ (0, _react.__styles)({
root: {}
}, {});
const useTeachingPopoverCarouselCardStyles_unstable = (state)=>{
'use no memo';
const styles = useStyles();
state.root.className = (0, _react.mergeClasses)(teachingPopoverCarouselCardClassNames.root, styles.root, state.root.className);
return state;
};
@@ -0,0 +1 @@
{"version":3,"sources":["useTeachingPopoverCarouselCardStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nexport const teachingPopoverCarouselCardClassNames = {\n root: 'fui-TeachingPopoverCarouselCard'\n};\nconst useStyles = makeStyles({\n root: {}\n});\n/** Applies style classnames to slots */ export const useTeachingPopoverCarouselCardStyles_unstable = (state)=>{\n 'use no memo';\n const styles = useStyles();\n state.root.className = mergeClasses(teachingPopoverCarouselCardClassNames.root, styles.root, state.root.className);\n return state;\n};\n"],"names":["teachingPopoverCarouselCardClassNames","useTeachingPopoverCarouselCardStyles_unstable","root","useStyles","__styles","state","styles","className","mergeClasses"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IACaA,qCAAqC;eAArCA;;IAMyCC,6CAA6C;eAA7CA;;;uBAPb;AAClC,MAAMD,wCAAwC;IACjDE,MAAM;AACV;AACA,MAAMC,YAAS,WAAA,GAAGC,IAAAA,eAAA,EAAA;IAAAF,MAAA,CAAA;AAAA,GAAA,CAAA;AAG8B,MAAMD,gDAAiDI,CAAAA;IACnG;IACA,MAAMC,SAASH;IACfE,MAAMH,IAAI,CAACK,SAAS,GAAGC,IAAAA,mBAAY,EAACR,sCAAsCE,IAAI,EAAEI,OAAOJ,IAAI,EAAEG,MAAMH,IAAI,CAACK,SAAS;IACjH,OAAOF;AACX"}
@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "TeachingPopoverCarouselFooter", {
enumerable: true,
get: function() {
return TeachingPopoverCarouselFooter;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useTeachingPopoverCarouselFooter = require("./useTeachingPopoverCarouselFooter");
const _renderTeachingPopoverCarouselFooter = require("./renderTeachingPopoverCarouselFooter");
const _useTeachingPopoverCarouselFooterStylesstyles = require("./useTeachingPopoverCarouselFooterStyles.styles");
const TeachingPopoverCarouselFooter = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useTeachingPopoverCarouselFooter.useTeachingPopoverCarouselFooter_unstable)(props, ref);
(0, _useTeachingPopoverCarouselFooterStylesstyles.useTeachingPopoverCarouselFooterStyles_unstable)(state);
return (0, _renderTeachingPopoverCarouselFooter.renderTeachingPopoverCarouselFooter_unstable)(state);
});
TeachingPopoverCarouselFooter.displayName = 'TeachingPopoverCarouselFooter';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useTeachingPopoverCarouselFooter_unstable } from './useTeachingPopoverCarouselFooter';\nimport { renderTeachingPopoverCarouselFooter_unstable } from './renderTeachingPopoverCarouselFooter';\nimport { useTeachingPopoverCarouselFooterStyles_unstable } from './useTeachingPopoverCarouselFooterStyles.styles';\nimport type { TeachingPopoverCarouselFooterProps } from './TeachingPopoverCarouselFooter.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * Define a styled TeachingPopoverCarouselFooter, using the `useTeachingPopoverCarouselFooter_unstable` and `useTeachingPopoverCarouselFooterStyles_unstable`\n * hooks.\n *\n * TeachingPopoverCarouselFooter contains previous/next buttons configured for carousel navigation, and a root slot for page count and/or page index navigation.\n */\nexport const TeachingPopoverCarouselFooter: ForwardRefComponent<TeachingPopoverCarouselFooterProps> = React.forwardRef(\n (props, ref) => {\n const state = useTeachingPopoverCarouselFooter_unstable(props, ref);\n\n useTeachingPopoverCarouselFooterStyles_unstable(state);\n\n return renderTeachingPopoverCarouselFooter_unstable(state);\n },\n);\n\nTeachingPopoverCarouselFooter.displayName = 'TeachingPopoverCarouselFooter';\n"],"names":["TeachingPopoverCarouselFooter","React","forwardRef","props","ref","state","useTeachingPopoverCarouselFooter_unstable","useTeachingPopoverCarouselFooterStyles_unstable","renderTeachingPopoverCarouselFooter_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAaaA;;;eAAAA;;;;iEAbU;kDACmC;qDACG;8DACG;AAUzD,MAAMA,gCAAAA,WAAAA,GAAyFC,OAAMC,UAAU,CACpH,CAACC,OAAOC;IACN,MAAMC,QAAQC,IAAAA,2EAAAA,EAA0CH,OAAOC;IAE/DG,IAAAA,6FAAAA,EAAgDF;IAEhD,OAAOG,IAAAA,iFAAAA,EAA6CH;AACtD;AAGFL,8BAA8BS,WAAW,GAAG"}
@@ -0,0 +1,6 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooter/TeachingPopoverCarouselFooter.types.ts"],"sourcesContent":["import * as React from 'react';\nimport type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport type { TeachingPopoverCarouselFooterButtonProps } from '../TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.types';\n\nexport type TeachingPopoverCarouselFooterSlots = {\n /**\n * The element wrapping carousel pages and navigation.\n */\n root: NonNullable<Slot<'div'>>;\n\n /**\n * The previous button slot.\n */\n previous?: Slot<TeachingPopoverCarouselFooterButtonProps>;\n\n /**\n * The next button slot.\n */\n next: NonNullable<Slot<TeachingPopoverCarouselFooterButtonProps>>;\n};\n\nexport type TeachingPopoverCarouselFooterLayout = 'offset' | 'centered';\n\n// For localization or customization, users may want to modify this for their own purposes\nexport type TeachingPopoverPageCountChildRenderFunction = (currentPage: number, totalPages: number) => React.ReactNode;\n\n/**\n * TeachingPopoverCarouselFooter Props\n */\nexport type TeachingPopoverCarouselFooterProps = ComponentProps<TeachingPopoverCarouselFooterSlots> & {\n /**\n * Controls whether buttons will be centered (balanced) or right aligned\n * Defaults to 'centered'.\n */\n layout?: TeachingPopoverCarouselFooterLayout;\n\n /**\n * The text to be displayed on the initial step of carousel\n */\n initialStepText: string;\n\n /**\n * The text to be displayed on the final step of carousel\n */\n finalStepText: string;\n};\n\n/**\n * TeachingPopoverCarouselFooter State and Context Hooks\n */\nexport type TeachingPopoverCarouselFooterState = ComponentState<Required<TeachingPopoverCarouselFooterSlots>> &\n Pick<TeachingPopoverCarouselFooterProps, 'layout'>;\n"],"names":[],"rangeMappings":";;;;;","mappings":";;;;;iEAAuB"}
@@ -0,0 +1,31 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
TeachingPopoverCarouselFooter: function() {
return _TeachingPopoverCarouselFooter.TeachingPopoverCarouselFooter;
},
renderTeachingPopoverCarouselFooter_unstable: function() {
return _renderTeachingPopoverCarouselFooter.renderTeachingPopoverCarouselFooter_unstable;
},
teachingPopoverCarouselFooterClassNames: function() {
return _useTeachingPopoverCarouselFooterStylesstyles.teachingPopoverCarouselFooterClassNames;
},
useTeachingPopoverCarouselFooterStyles_unstable: function() {
return _useTeachingPopoverCarouselFooterStylesstyles.useTeachingPopoverCarouselFooterStyles_unstable;
},
useTeachingPopoverCarouselFooter_unstable: function() {
return _useTeachingPopoverCarouselFooter.useTeachingPopoverCarouselFooter_unstable;
}
});
const _TeachingPopoverCarouselFooter = require("./TeachingPopoverCarouselFooter");
const _renderTeachingPopoverCarouselFooter = require("./renderTeachingPopoverCarouselFooter");
const _useTeachingPopoverCarouselFooter = require("./useTeachingPopoverCarouselFooter");
const _useTeachingPopoverCarouselFooterStylesstyles = require("./useTeachingPopoverCarouselFooterStyles.styles");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooter/index.ts"],"sourcesContent":["export { TeachingPopoverCarouselFooter } from './TeachingPopoverCarouselFooter';\nexport type {\n TeachingPopoverCarouselFooterLayout,\n TeachingPopoverCarouselFooterProps,\n TeachingPopoverCarouselFooterSlots,\n TeachingPopoverCarouselFooterState,\n TeachingPopoverPageCountChildRenderFunction,\n} from './TeachingPopoverCarouselFooter.types';\nexport { renderTeachingPopoverCarouselFooter_unstable } from './renderTeachingPopoverCarouselFooter';\nexport { useTeachingPopoverCarouselFooter_unstable } from './useTeachingPopoverCarouselFooter';\nexport {\n teachingPopoverCarouselFooterClassNames,\n useTeachingPopoverCarouselFooterStyles_unstable,\n} from './useTeachingPopoverCarouselFooterStyles.styles';\n"],"names":["TeachingPopoverCarouselFooter","renderTeachingPopoverCarouselFooter_unstable","teachingPopoverCarouselFooterClassNames","useTeachingPopoverCarouselFooterStyles_unstable","useTeachingPopoverCarouselFooter_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,6BAA6B;eAA7BA,4DAA6B;;IAQ7BC,4CAA4C;eAA5CA,iFAA4C;;IAGnDC,uCAAuC;eAAvCA,qFAAuC;;IACvCC,+CAA+C;eAA/CA,6FAA+C;;IAHxCC,yCAAyC;eAAzCA,2EAAyC;;;+CATJ;qDAQe;kDACH;8DAInD"}
@@ -0,0 +1,24 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderTeachingPopoverCarouselFooter_unstable", {
enumerable: true,
get: function() {
return renderTeachingPopoverCarouselFooter_unstable;
}
});
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
const _reactutilities = require("@fluentui/react-utilities");
const renderTeachingPopoverCarouselFooter_unstable = (state)=>{
(0, _reactutilities.assertSlots)(state);
const { layout } = state;
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(state.root, {
children: [
layout === 'centered' && state.previous && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.previous, {}),
state.root.children,
layout === 'offset' && state.previous && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.previous, {}),
/*#__PURE__*/ (0, _jsxruntime.jsx)(state.next, {})
]
});
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooter/renderTeachingPopoverCarouselFooter.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\nimport type { TeachingPopoverCarouselFooterState } from './TeachingPopoverCarouselFooter.types';\nimport { TeachingPopoverCarouselFooterSlots } from './TeachingPopoverCarouselFooter.types';\nimport { assertSlots } from '@fluentui/react-utilities';\n\n/**\n * Render the final JSX of TeachingPopoverCarouselFooter\n */\nexport const renderTeachingPopoverCarouselFooter_unstable = (state: TeachingPopoverCarouselFooterState) => {\n assertSlots<TeachingPopoverCarouselFooterSlots>(state);\n\n const { layout } = state;\n\n return (\n <state.root>\n {layout === 'centered' && state.previous && <state.previous />}\n {state.root.children}\n {layout === 'offset' && state.previous && <state.previous />}\n <state.next />\n </state.root>\n );\n};\n"],"names":["renderTeachingPopoverCarouselFooter_unstable","state","assertSlots","layout","_jsxs","root","previous","_jsx","children","next"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;gCAG4B;AAKrB,MAAMA,+CAA+C,CAACC;IAC3DC,IAAAA,2BAAAA,EAAgDD;IAEhD,MAAM,EAAEE,MAAM,EAAE,GAAGF;IAEnB,OAAA,WAAA,GACEG,IAAAA,gBAAA,EAACH,MAAMI,IAAI,EAAA;;YACRF,WAAW,cAAcF,MAAMK,QAAQ,IAAA,WAAA,GAAIC,IAAAA,eAAA,EAACN,MAAMK,QAAQ,EAAA,CAAA;YAC1DL,MAAMI,IAAI,CAACG,QAAQ;YACnBL,WAAW,YAAYF,MAAMK,QAAQ,IAAA,WAAA,GAAIC,IAAAA,eAAA,EAACN,MAAMK,QAAQ,EAAA,CAAA;0BACzDC,IAAAA,eAAA,EAACN,MAAMQ,IAAI,EAAA,CAAA;;;AAGjB"}
@@ -0,0 +1,48 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useTeachingPopoverCarouselFooter_unstable", {
enumerable: true,
get: function() {
return useTeachingPopoverCarouselFooter_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _reactutilities = require("@fluentui/react-utilities");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _TeachingPopoverCarouselFooterButton = require("../TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton");
const useTeachingPopoverCarouselFooter_unstable = (props, ref)=>{
const { layout = 'centered', initialStepText, finalStepText } = props;
const previous = _reactutilities.slot.optional(props.previous, {
defaultProps: {
navType: 'prev',
altText: initialStepText
},
renderByDefault: true,
elementType: _TeachingPopoverCarouselFooterButton.TeachingPopoverCarouselFooterButton
});
const next = _reactutilities.slot.always(props.next, {
defaultProps: {
navType: 'next',
altText: finalStepText
},
elementType: _TeachingPopoverCarouselFooterButton.TeachingPopoverCarouselFooterButton
});
return {
layout,
components: {
root: 'div',
next: _TeachingPopoverCarouselFooterButton.TeachingPopoverCarouselFooterButton,
previous: _TeachingPopoverCarouselFooterButton.TeachingPopoverCarouselFooterButton
},
root: _reactutilities.slot.always((0, _reactutilities.getIntrinsicElementProps)('div', {
ref,
...props
}), {
elementType: 'div'
}),
previous,
next
};
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooter/useTeachingPopoverCarouselFooter.ts"],"sourcesContent":["import { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';\nimport * as React from 'react';\n\nimport type {\n TeachingPopoverCarouselFooterProps,\n TeachingPopoverCarouselFooterState,\n} from './TeachingPopoverCarouselFooter.types';\nimport { TeachingPopoverCarouselFooterButton } from '../TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton';\n\nexport const useTeachingPopoverCarouselFooter_unstable = (\n props: TeachingPopoverCarouselFooterProps,\n ref: React.Ref<HTMLDivElement>,\n): TeachingPopoverCarouselFooterState => {\n const { layout = 'centered', initialStepText, finalStepText } = props;\n\n const previous = slot.optional(props.previous, {\n defaultProps: {\n navType: 'prev',\n altText: initialStepText,\n },\n renderByDefault: true,\n elementType: TeachingPopoverCarouselFooterButton,\n });\n\n const next = slot.always(props.next, {\n defaultProps: {\n navType: 'next',\n altText: finalStepText,\n },\n elementType: TeachingPopoverCarouselFooterButton,\n });\n\n return {\n layout,\n components: {\n root: 'div',\n next: TeachingPopoverCarouselFooterButton,\n previous: TeachingPopoverCarouselFooterButton,\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n previous,\n next,\n };\n};\n"],"names":["useTeachingPopoverCarouselFooter_unstable","props","ref","layout","initialStepText","finalStepText","previous","slot","optional","defaultProps","navType","altText","renderByDefault","elementType","TeachingPopoverCarouselFooterButton","next","always","components","root","getIntrinsicElementProps"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;;gCATkC;iEACxB;qDAM6B;AAE7C,MAAMA,4CAA4C,CACvDC,OACAC;IAEA,MAAM,EAAEC,SAAS,UAAU,EAAEC,eAAe,EAAEC,aAAa,EAAE,GAAGJ;IAEhE,MAAMK,WAAWC,oBAAAA,CAAKC,QAAQ,CAACP,MAAMK,QAAQ,EAAE;QAC7CG,cAAc;YACZC,SAAS;YACTC,SAASP;QACX;QACAQ,iBAAiB;QACjBC,aAAaC,wEAAAA;IACf;IAEA,MAAMC,OAAOR,oBAAAA,CAAKS,MAAM,CAACf,MAAMc,IAAI,EAAE;QACnCN,cAAc;YACZC,SAAS;YACTC,SAASN;QACX;QACAQ,aAAaC,wEAAAA;IACf;IAEA,OAAO;QACLX;QACAc,YAAY;YACVC,MAAM;YACNH,MAAMD,wEAAAA;YACNR,UAAUQ,wEAAAA;QACZ;QACAI,MAAMX,oBAAAA,CAAKS,MAAM,CACfG,IAAAA,wCAAAA,EAAyB,OAAO;YAC9BjB;YACA,GAAGD,KAAK;QACV,IACA;YAAEY,aAAa;QAAM;QAEvBP;QACAS;IACF;AACF"}
@@ -0,0 +1,73 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
teachingPopoverCarouselFooterClassNames: function() {
return teachingPopoverCarouselFooterClassNames;
},
useTeachingPopoverCarouselFooterStyles_unstable: function() {
return useTeachingPopoverCarouselFooterStyles_unstable;
}
});
const _react = require("@griffel/react");
const teachingPopoverCarouselFooterClassNames = {
root: 'fui-TeachingPopoverCarouselFooter',
previous: 'fui-TeachingPopoverCarouselFooter__previous',
next: 'fui-TeachingPopoverCarouselFooter__next'
};
// Todo: Page change animation & styles
const useStyles = /*#__PURE__*/ (0, _react.__styles)({
root: {
mc9l5x: "f22iagw",
Beiy3e4: "f1063pyq"
},
rootCentered: {
Brf1p80: "f1869bpl",
i8kkvl: 0,
Belr9w4: 0,
rmohyg: "f19gb1f4"
},
rootRightAligned: {
i8kkvl: 0,
Belr9w4: 0,
rmohyg: "f19gb1f4",
Bp34fd5: "f1y65ohq"
}
}, {
d: [
".f22iagw{display:flex;}",
".f1063pyq{flex-direction:row;}",
".f1869bpl{justify-content:space-between;}",
[
".f19gb1f4{gap:8px;}",
{
p: -1
}
],
[
".f19gb1f4{gap:8px;}",
{
p: -1
}
],
".f1y65ohq :first-child{-webkit-margin-end:auto;margin-inline-end:auto;}"
]
});
const useTeachingPopoverCarouselFooterStyles_unstable = (state)=>{
'use no memo';
const styles = useStyles();
const { layout } = state;
state.root.className = (0, _react.mergeClasses)(teachingPopoverCarouselFooterClassNames.root, styles.root, layout === 'centered' ? styles.rootCentered : styles.rootRightAligned, state.root.className);
if (state.previous) {
state.previous.className = (0, _react.mergeClasses)(teachingPopoverCarouselFooterClassNames.previous, state.previous.className);
}
state.next.className = (0, _react.mergeClasses)(teachingPopoverCarouselFooterClassNames.next, state.next.className);
return state;
};
@@ -0,0 +1 @@
{"version":3,"sources":["useTeachingPopoverCarouselFooterStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nexport const teachingPopoverCarouselFooterClassNames = {\n root: 'fui-TeachingPopoverCarouselFooter',\n previous: 'fui-TeachingPopoverCarouselFooter__previous',\n next: 'fui-TeachingPopoverCarouselFooter__next'\n};\n// Todo: Page change animation & styles\nconst useStyles = makeStyles({\n root: {\n display: 'flex',\n flexDirection: 'row'\n },\n rootCentered: {\n justifyContent: 'space-between',\n gap: '8px'\n },\n rootRightAligned: {\n gap: '8px',\n '& :first-child': {\n marginInlineEnd: 'auto'\n }\n }\n});\n/** Applies style classnames to slots */ export const useTeachingPopoverCarouselFooterStyles_unstable = (state)=>{\n 'use no memo';\n const styles = useStyles();\n const { layout } = state;\n state.root.className = mergeClasses(teachingPopoverCarouselFooterClassNames.root, styles.root, layout === 'centered' ? styles.rootCentered : styles.rootRightAligned, state.root.className);\n if (state.previous) {\n state.previous.className = mergeClasses(teachingPopoverCarouselFooterClassNames.previous, state.previous.className);\n }\n state.next.className = mergeClasses(teachingPopoverCarouselFooterClassNames.next, state.next.className);\n return state;\n};\n"],"names":["teachingPopoverCarouselFooterClassNames","useTeachingPopoverCarouselFooterStyles_unstable","root","previous","next","useStyles","__styles","mc9l5x","Beiy3e4","rootCentered","Brf1p80","i8kkvl","Belr9w4","rmohyg","rootRightAligned","Bp34fd5","d","p","state","styles","layout","className","mergeClasses"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IACaA,uCAAuC;eAAvCA;;IAsByCC,+CAA+C;eAA/CA;;;uBAvBb;AAClC,MAAMD,0CAA0C;IACnDE,MAAM;IACNC,UAAU;IACVC,MAAM;AACV;AACA,uCAAA;AACA,MAAMC,YAAS,WAAA,GAAGC,IAAAA,eAAA,EAAA;IAAAJ,MAAA;QAAAK,QAAA;QAAAC,SAAA;IAAA;IAAAC,cAAA;QAAAC,SAAA;QAAAC,QAAA;QAAAC,SAAA;QAAAC,QAAA;IAAA;IAAAC,kBAAA;QAAAH,QAAA;QAAAC,SAAA;QAAAC,QAAA;QAAAE,SAAA;IAAA;AAAA,GAAA;IAAAC,GAAA;QAAA;QAAA;QAAA;QAAA;YAAA;YAAA;gBAAAC,GAAA,CAAA;YAAA;SAAA;QAAA;YAAA;YAAA;gBAAAA,GAAA,CAAA;YAAA;SAAA;QAAA;KAAA;AAAA;AAgB8B,MAAMhB,kDAAmDiB,CAAAA;IACrG;IACA,MAAMC,SAASd;IACf,MAAM,EAAEe,MAAAA,EAAQ,GAAGF;IACnBA,MAAMhB,IAAI,CAACmB,SAAS,GAAGC,IAAAA,mBAAY,EAACtB,wCAAwCE,IAAI,EAAEiB,OAAOjB,IAAI,EAAEkB,WAAW,aAAaD,OAAOV,YAAY,GAAGU,OAAOL,gBAAgB,EAAEI,MAAMhB,IAAI,CAACmB,SAAS;IAC1L,IAAIH,MAAMf,QAAQ,EAAE;QAChBe,MAAMf,QAAQ,CAACkB,SAAS,GAAGC,IAAAA,mBAAY,EAACtB,wCAAwCG,QAAQ,EAAEe,MAAMf,QAAQ,CAACkB,SAAS;IACtH;IACAH,MAAMd,IAAI,CAACiB,SAAS,GAAGC,IAAAA,mBAAY,EAACtB,wCAAwCI,IAAI,EAAEc,MAAMd,IAAI,CAACiB,SAAS;IACtG,OAAOH;AACX"}
@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "TeachingPopoverCarouselFooterButton", {
enumerable: true,
get: function() {
return TeachingPopoverCarouselFooterButton;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useTeachingPopoverCarouselFooterButton = require("./useTeachingPopoverCarouselFooterButton");
const _renderTeachingPopoverCarouselFooterButton = require("./renderTeachingPopoverCarouselFooterButton");
const _useTeachingPopoverCarouselFooterButtonStylesstyles = require("./useTeachingPopoverCarouselFooterButtonStyles.styles");
const TeachingPopoverCarouselFooterButton = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useTeachingPopoverCarouselFooterButton.useTeachingPopoverCarouselFooterButton_unstable)(props, ref);
(0, _useTeachingPopoverCarouselFooterButtonStylesstyles.useTeachingPopoverCarouselFooterButtonStyles_unstable)(state);
return (0, _renderTeachingPopoverCarouselFooterButton.renderTeachingPopoverCarouselFooterButton_unstable)(state);
});
TeachingPopoverCarouselFooterButton.displayName = 'TeachingPopoverCarouselFooterButton';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.tsx"],"sourcesContent":["import * as React from 'react';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useTeachingPopoverCarouselFooterButton_unstable } from './useTeachingPopoverCarouselFooterButton';\nimport { renderTeachingPopoverCarouselFooterButton_unstable } from './renderTeachingPopoverCarouselFooterButton';\nimport { useTeachingPopoverCarouselFooterButtonStyles_unstable } from './useTeachingPopoverCarouselFooterButtonStyles.styles';\nimport type { TeachingPopoverCarouselFooterButtonProps } from './TeachingPopoverCarouselFooterButton.types';\n\n/**\n * TeachingPopoverCarouselFooterButton component\n *\n * TeachingPopoverCarouselFooterButton extends Button and injects additional styling and onClick functionality\n * to match the context provided by TeachingPopover & TeachingPopoverCarousel\n */\nexport const TeachingPopoverCarouselFooterButton: ForwardRefComponent<TeachingPopoverCarouselFooterButtonProps> =\n React.forwardRef((props, ref) => {\n const state = useTeachingPopoverCarouselFooterButton_unstable(props, ref);\n\n useTeachingPopoverCarouselFooterButtonStyles_unstable(state);\n\n return renderTeachingPopoverCarouselFooterButton_unstable(state);\n });\n\nTeachingPopoverCarouselFooterButton.displayName = 'TeachingPopoverCarouselFooterButton';\n"],"names":["TeachingPopoverCarouselFooterButton","React","forwardRef","props","ref","state","useTeachingPopoverCarouselFooterButton_unstable","useTeachingPopoverCarouselFooterButtonStyles_unstable","renderTeachingPopoverCarouselFooterButton_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAaaA;;;eAAAA;;;;iEAbU;wDAEyC;2DACG;oEACG;AAS/D,MAAMA,sCAAAA,WAAAA,GACXC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IACvB,MAAMC,QAAQC,IAAAA,uFAAAA,EAAgDH,OAAOC;IAErEG,IAAAA,yGAAAA,EAAsDF;IAEtD,OAAOG,IAAAA,6FAAAA,EAAmDH;AAC5D;AAEFL,oCAAoCS,WAAW,GAAG"}
@@ -0,0 +1,6 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooterButton/TeachingPopoverCarouselFooterButton.types.ts"],"sourcesContent":["import * as React from 'react';\nimport type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\nimport { PopoverContextValue } from '@fluentui/react-popover';\nimport { ButtonProps, ButtonState } from '@fluentui/react-button';\nimport { ARIAButtonSlotProps } from '@fluentui/react-aria';\n\nexport type TeachingPopoverCarouselFooterButtonSlots = {\n root: NonNullable<Slot<ARIAButtonSlotProps<'a'>>>;\n};\n\n/**\n * TeachingPopoverCarouselFooterButton Props\n */\nexport type TeachingPopoverCarouselFooterButtonProps = ComponentProps<TeachingPopoverCarouselFooterButtonSlots> &\n ButtonProps & {\n /**\n * Defines whether the button should be next or previous type - used for both styling and functionality.\n */\n navType: 'next' | 'prev';\n\n /**\n * The ReactNode provided to the button when it is on it's first (navType 'prev') or last (navType 'next') step\n */\n altText: React.ReactNode;\n };\n\n/**\n * State used in rendering TeachingPopoverCarouselFooterButton\n */\nexport type TeachingPopoverCarouselFooterButtonState = ButtonState &\n ComponentState<TeachingPopoverCarouselFooterButtonSlots> &\n Pick<TeachingPopoverCarouselFooterButtonProps, 'navType' | 'altText'> & {\n /* Rename popover appearance to prevent conflict with button appearance */\n popoverAppearance: PopoverContextValue['appearance'];\n };\n"],"names":[],"rangeMappings":";;;;;","mappings":";;;;;iEAAuB"}
@@ -0,0 +1,31 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
TeachingPopoverCarouselFooterButton: function() {
return _TeachingPopoverCarouselFooterButton.TeachingPopoverCarouselFooterButton;
},
renderTeachingPopoverCarouselFooterButton_unstable: function() {
return _renderTeachingPopoverCarouselFooterButton.renderTeachingPopoverCarouselFooterButton_unstable;
},
teachingPopoverCarouselFooterButtonClassNames: function() {
return _useTeachingPopoverCarouselFooterButtonStylesstyles.teachingPopoverCarouselFooterButtonClassNames;
},
useTeachingPopoverCarouselFooterButtonStyles_unstable: function() {
return _useTeachingPopoverCarouselFooterButtonStylesstyles.useTeachingPopoverCarouselFooterButtonStyles_unstable;
},
useTeachingPopoverCarouselFooterButton_unstable: function() {
return _useTeachingPopoverCarouselFooterButton.useTeachingPopoverCarouselFooterButton_unstable;
}
});
const _TeachingPopoverCarouselFooterButton = require("./TeachingPopoverCarouselFooterButton");
const _renderTeachingPopoverCarouselFooterButton = require("./renderTeachingPopoverCarouselFooterButton");
const _useTeachingPopoverCarouselFooterButton = require("./useTeachingPopoverCarouselFooterButton");
const _useTeachingPopoverCarouselFooterButtonStylesstyles = require("./useTeachingPopoverCarouselFooterButtonStyles.styles");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooterButton/index.ts"],"sourcesContent":["export { TeachingPopoverCarouselFooterButton } from './TeachingPopoverCarouselFooterButton';\nexport type {\n TeachingPopoverCarouselFooterButtonProps,\n TeachingPopoverCarouselFooterButtonSlots,\n TeachingPopoverCarouselFooterButtonState,\n} from './TeachingPopoverCarouselFooterButton.types';\nexport { renderTeachingPopoverCarouselFooterButton_unstable } from './renderTeachingPopoverCarouselFooterButton';\nexport { useTeachingPopoverCarouselFooterButton_unstable } from './useTeachingPopoverCarouselFooterButton';\nexport {\n teachingPopoverCarouselFooterButtonClassNames,\n useTeachingPopoverCarouselFooterButtonStyles_unstable,\n} from './useTeachingPopoverCarouselFooterButtonStyles.styles';\n"],"names":["TeachingPopoverCarouselFooterButton","renderTeachingPopoverCarouselFooterButton_unstable","teachingPopoverCarouselFooterButtonClassNames","useTeachingPopoverCarouselFooterButtonStyles_unstable","useTeachingPopoverCarouselFooterButton_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,mCAAmC;eAAnCA,wEAAmC;;IAMnCC,kDAAkD;eAAlDA,6FAAkD;;IAGzDC,6CAA6C;eAA7CA,iGAA6C;;IAC7CC,qDAAqD;eAArDA,yGAAqD;;IAH9CC,+CAA+C;eAA/CA,uFAA+C;;;qDAPJ;2DAMe;wDACH;oEAIzD"}
@@ -0,0 +1,16 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderTeachingPopoverCarouselFooterButton_unstable", {
enumerable: true,
get: function() {
return renderTeachingPopoverCarouselFooterButton_unstable;
}
});
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
const _reactutilities = require("@fluentui/react-utilities");
const renderTeachingPopoverCarouselFooterButton_unstable = (state)=>{
(0, _reactutilities.assertSlots)(state);
return /*#__PURE__*/ (0, _jsxruntime.jsx)(state.root, {});
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselFooterButton/renderTeachingPopoverCarouselFooterButton.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type {\n TeachingPopoverCarouselFooterButtonState,\n TeachingPopoverCarouselFooterButtonSlots,\n} from './TeachingPopoverCarouselFooterButton.types';\n\n/**\n * Render the final JSX of TeachingPopoverCarouselFooterButton\n */\nexport const renderTeachingPopoverCarouselFooterButton_unstable = (state: TeachingPopoverCarouselFooterButtonState) => {\n assertSlots<TeachingPopoverCarouselFooterButtonSlots>(state);\n\n return <state.root />;\n};\n"],"names":["renderTeachingPopoverCarouselFooterButton_unstable","state","assertSlots","_jsx","root"],"rangeMappings":";;;;;;;;;;;;;;;","mappings":";;;;+BAYaA;;;eAAAA;;;4BAXb;gCAE4B;AASrB,MAAMA,qDAAqD,CAACC;IACjEC,IAAAA,2BAAAA,EAAsDD;IAEtD,OAAA,WAAA,GAAOE,IAAAA,eAAA,EAACF,MAAMG,IAAI,EAAA,CAAA;AACpB"}
@@ -0,0 +1,73 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useTeachingPopoverCarouselFooterButton_unstable", {
enumerable: true,
get: function() {
return useTeachingPopoverCarouselFooterButton_unstable;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _reactutilities = require("@fluentui/react-utilities");
const _reactpopover = require("@fluentui/react-popover");
const _CarouselContext = require("../TeachingPopoverCarousel/Carousel/CarouselContext");
const _reactbutton = require("@fluentui/react-button");
const _useCarouselValues = require("../TeachingPopoverCarousel/Carousel/useCarouselValues");
const useTeachingPopoverCarouselFooterButton_unstable = (props, ref)=>{
const { navType, altText } = props;
const popoverAppearance = (0, _reactpopover.usePopoverContext_unstable)((context)=>context.appearance);
const selectPageByDirection = (0, _CarouselContext.useCarouselContext_unstable)((c)=>c.selectPageByDirection);
const values = (0, _useCarouselValues.useCarouselValues_unstable)((snapshot)=>snapshot);
const activeValue = (0, _CarouselContext.useCarouselContext_unstable)((c)=>c.value);
const handleClick = (event)=>{
if (event.isDefaultPrevented()) {
return;
}
selectPageByDirection(event, navType);
};
const handleButtonClick = (0, _reactutilities.useEventCallback)((0, _reactutilities.mergeCallbacks)(handleClick, props.onClick));
const isTrailing = _react.useMemo(()=>{
if (!activeValue) {
return false;
}
if (navType === 'prev') {
return values.indexOf(activeValue) === 0;
}
return values.indexOf(activeValue) === values.length - 1;
}, [
navType,
activeValue,
values
]);
let buttonAppearanceType;
if (navType === 'next') {
buttonAppearanceType = popoverAppearance === 'brand' ? undefined : 'primary';
} else {
buttonAppearanceType = popoverAppearance === 'brand' ? 'outline' : undefined;
}
/* Handle altText on trailing step */ let buttonChild = props.children;
if (isTrailing) {
buttonChild = altText;
}
return {
...(0, _reactbutton.useButton_unstable)({
appearance: buttonAppearanceType,
...props
}, ref),
navType,
popoverAppearance,
altText,
// Override useButton root slot
root: _reactutilities.slot.always((0, _reactutilities.getIntrinsicElementProps)('button', {
ref,
appearance: buttonAppearanceType,
...props,
onClick: handleButtonClick,
children: buttonChild
}), {
elementType: 'button'
})
};
};
@@ -0,0 +1,130 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
teachingPopoverCarouselFooterButtonClassNames: function() {
return teachingPopoverCarouselFooterButtonClassNames;
},
useTeachingPopoverCarouselFooterButtonStyles_unstable: function() {
return useTeachingPopoverCarouselFooterButtonStyles_unstable;
}
});
const _react = require("@griffel/react");
const _reactbutton = require("@fluentui/react-button");
const teachingPopoverCarouselFooterButtonClassNames = {
root: 'fui-TeachingPopoverCarouselFooterButton'
};
const useStyles = /*#__PURE__*/ (0, _react.__styles)({
root: {
Bf4jedk: "f14es27b"
},
brandNext: {
sj55zd: "f16muhyy",
De3pzq: "f10s6wn9",
g2u3we: "f1iimpp0",
h3c5rm: [
"f19uhqvu",
"f1nx14hx"
],
B9xav0g: "fnqa90p",
zhjwy3: [
"f1nx14hx",
"f19uhqvu"
],
Bi91k9c: "f3ymbdj",
Jwef8y: "f1rgtb95",
B2d53fq: "f1pu27ff",
iro3zm: "f1d5c7in"
},
brandPrevious: {
sj55zd: "f1phragk",
De3pzq: "ffp7eso",
g2u3we: "fm1ebug",
h3c5rm: [
"f28omuz",
"f1uhflii"
],
B9xav0g: "f1ixw5o4",
zhjwy3: [
"f1uhflii",
"f28omuz"
],
Bi91k9c: "f1rq72xc",
Bgoe8wy: "f1bg5g8r",
Bwzppfd: [
"f1h9bnsk",
"f12x9t0k"
],
oetu4i: "f19ervry",
gg5e9n: [
"f12x9t0k",
"f1h9bnsk"
],
Jwef8y: "f15wkkf3",
B2d53fq: "f1d6v5y2",
b661bw: "f1565b9n",
Bk6r4ia: [
"fm07gvo",
"fwlsg72"
],
B9zn80p: "fzw6fmy",
Bpld233: [
"fwlsg72",
"fm07gvo"
],
iro3zm: "fnp9lpt"
}
}, {
d: [
".f14es27b{min-width:96px;}",
".f16muhyy{color:var(--colorBrandForeground1);}",
".f10s6wn9{background-color:var(--colorNeutralForegroundOnBrand);}",
".f1iimpp0{border-top-color:var(--colorTransparentBackground);}",
".f19uhqvu{border-right-color:var(--colorTransparentBackground);}",
".f1nx14hx{border-left-color:var(--colorTransparentBackground);}",
".fnqa90p{border-bottom-color:var(--colorTransparentBackground);}",
".f1phragk{color:var(--colorNeutralForegroundOnBrand);}",
".ffp7eso{background-color:var(--colorBrandBackground);}",
".fm1ebug{border-top-color:var(--colorNeutralForegroundOnBrand);}",
".f28omuz{border-right-color:var(--colorNeutralForegroundOnBrand);}",
".f1uhflii{border-left-color:var(--colorNeutralForegroundOnBrand);}",
".f1ixw5o4{border-bottom-color:var(--colorNeutralForegroundOnBrand);}"
],
h: [
".f3ymbdj:hover{color:var(--colorCompoundBrandForeground1Hover);}",
".f1rgtb95:hover{background-color:var(--colorNeutralForegroundOnBrand);}",
".f1pu27ff:hover:active{color:var(--colorCompoundBrandForeground1Pressed);}",
".f1d5c7in:hover:active{background-color:var(--colorNeutralForegroundOnBrand);}",
".f1rq72xc:hover{color:var(--colorNeutralForegroundOnBrand);}",
".f1bg5g8r:hover{border-top-color:var(--colorNeutralForegroundOnBrand);}",
".f1h9bnsk:hover{border-right-color:var(--colorNeutralForegroundOnBrand);}",
".f12x9t0k:hover{border-left-color:var(--colorNeutralForegroundOnBrand);}",
".f19ervry:hover{border-bottom-color:var(--colorNeutralForegroundOnBrand);}",
".f15wkkf3:hover{background-color:var(--colorBrandBackgroundHover);}",
".f1d6v5y2:hover:active{color:var(--colorNeutralForegroundOnBrand);}",
".f1565b9n:hover:active{border-top-color:var(--colorNeutralForegroundOnBrand);}",
".fm07gvo:hover:active{border-right-color:var(--colorNeutralForegroundOnBrand);}",
".fwlsg72:hover:active{border-left-color:var(--colorNeutralForegroundOnBrand);}",
".fzw6fmy:hover:active{border-bottom-color:var(--colorNeutralForegroundOnBrand);}",
".fnp9lpt:hover:active{background-color:var(--colorBrandBackgroundPressed);}"
]
});
const useTeachingPopoverCarouselFooterButtonStyles_unstable = (state)=>{
'use no memo';
const styles = useStyles();
const { navType, popoverAppearance } = state;
// Apply underlying fluent Button styles
state = {
...state,
...(0, _reactbutton.useButtonStyles_unstable)(state)
};
state.root.className = (0, _react.mergeClasses)(teachingPopoverCarouselFooterButtonClassNames.root, styles.root, navType === 'prev' && popoverAppearance === 'brand' && styles.brandPrevious, navType === 'next' && popoverAppearance === 'brand' && styles.brandNext, state.root.className);
return state;
};
@@ -0,0 +1 @@
{"version":3,"sources":["useTeachingPopoverCarouselFooterButtonStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport { useButtonStyles_unstable } from '@fluentui/react-button';\nexport const teachingPopoverCarouselFooterButtonClassNames = {\n root: 'fui-TeachingPopoverCarouselFooterButton'\n};\nconst useStyles = makeStyles({\n root: {\n minWidth: '96px'\n },\n brandNext: {\n color: tokens.colorBrandForeground1,\n backgroundColor: tokens.colorNeutralForegroundOnBrand,\n ...shorthands.borderColor(tokens.colorTransparentBackground),\n ':hover': {\n color: tokens.colorCompoundBrandForeground1Hover,\n backgroundColor: tokens.colorNeutralForegroundOnBrand\n },\n ':hover:active': {\n color: tokens.colorCompoundBrandForeground1Pressed,\n backgroundColor: tokens.colorNeutralForegroundOnBrand\n }\n },\n brandPrevious: {\n // In brand, this is always 'NeutralForegroundOnBrand'\n color: tokens.colorNeutralForegroundOnBrand,\n backgroundColor: tokens.colorBrandBackground,\n ...shorthands.borderColor(tokens.colorNeutralForegroundOnBrand),\n ':hover': {\n color: tokens.colorNeutralForegroundOnBrand,\n ...shorthands.borderColor(tokens.colorNeutralForegroundOnBrand),\n backgroundColor: tokens.colorBrandBackgroundHover\n },\n ':hover:active': {\n color: tokens.colorNeutralForegroundOnBrand,\n ...shorthands.borderColor(tokens.colorNeutralForegroundOnBrand),\n backgroundColor: tokens.colorBrandBackgroundPressed\n }\n }\n});\n/**\n * Apply styling to the TeachingPopoverCarouselFooterButton slots based on the state\n */ export const useTeachingPopoverCarouselFooterButtonStyles_unstable = (state)=>{\n 'use no memo';\n const styles = useStyles();\n const { navType, popoverAppearance } = state;\n // Apply underlying fluent Button styles\n state = {\n ...state,\n ...useButtonStyles_unstable(state)\n };\n state.root.className = mergeClasses(teachingPopoverCarouselFooterButtonClassNames.root, styles.root, navType === 'prev' && popoverAppearance === 'brand' && styles.brandPrevious, navType === 'next' && popoverAppearance === 'brand' && styles.brandNext, state.root.className);\n return state;\n};\n"],"names":["teachingPopoverCarouselFooterButtonClassNames","useTeachingPopoverCarouselFooterButtonStyles_unstable","root","useStyles","__styles","Bf4jedk","brandNext","sj55zd","De3pzq","g2u3we","h3c5rm","B9xav0g","zhjwy3","Bi91k9c","Jwef8y","B2d53fq","iro3zm","brandPrevious","Bgoe8wy","Bwzppfd","oetu4i","gg5e9n","b661bw","Bk6r4ia","B9zn80p","Bpld233","d","h","state","styles","navType","popoverAppearance","useButtonStyles_unstable","className","mergeClasses"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAGaA,6CAA6C;eAA7CA;;IAuCIC,qDAAqD;eAArDA;;;uBA1CoC;6BAEZ;AAClC,MAAMD,gDAAgD;IACzDE,MAAM;AACV;AACA,MAAMC,YAAS,WAAA,GAAGC,IAAAA,eAAA,EAAA;IAAAF,MAAA;QAAAG,SAAA;IAAA;IAAAC,WAAA;QAAAC,QAAA;QAAAC,QAAA;QAAAC,QAAA;QAAAC,QAAA;YAAA;YAAA;SAAA;QAAAC,SAAA;QAAAC,QAAA;YAAA;YAAA;SAAA;QAAAC,SAAA;QAAAC,QAAA;QAAAC,SAAA;QAAAC,QAAA;IAAA;IAAAC,eAAA;QAAAV,QAAA;QAAAC,QAAA;QAAAC,QAAA;QAAAC,QAAA;YAAA;YAAA;SAAA;QAAAC,SAAA;QAAAC,QAAA;YAAA;YAAA;SAAA;QAAAC,SAAA;QAAAK,SAAA;QAAAC,SAAA;YAAA;YAAA;SAAA;QAAAC,QAAA;QAAAC,QAAA;YAAA;YAAA;SAAA;QAAAP,QAAA;QAAAC,SAAA;QAAAO,QAAA;QAAAC,SAAA;YAAA;YAAA;SAAA;QAAAC,SAAA;QAAAC,SAAA;YAAA;YAAA;SAAA;QAAAT,QAAA;IAAA;AAAA,GAAA;IAAAU,GAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;KAAA;IAAAC,GAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;KAAA;AAAA;AAoCP,MAAM1B,wDAAyD2B,CAAAA;IACtE;IACA,MAAMC,SAAS1B;IACf,MAAM,EAAE2B,OAAO,EAAEC,iBAAAA,EAAmB,GAAGH;IACvC,wCAAA;IACAA,QAAQ;QACJ,GAAGA,KAAK;QACR,GAAGI,IAAAA,qCAAwB,EAACJ,MAAK;IACrC;IACAA,MAAM1B,IAAI,CAAC+B,SAAS,GAAGC,IAAAA,mBAAY,EAAClC,8CAA8CE,IAAI,EAAE2B,OAAO3B,IAAI,EAAE4B,YAAY,UAAUC,sBAAsB,WAAWF,OAAOZ,aAAa,EAAEa,YAAY,UAAUC,sBAAsB,WAAWF,OAAOvB,SAAS,EAAEsB,MAAM1B,IAAI,CAAC+B,SAAS;IAC/Q,OAAOL;AACX"}
@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "TeachingPopoverCarouselNav", {
enumerable: true,
get: function() {
return TeachingPopoverCarouselNav;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _useTeachingPopoverCarouselNav = require("./useTeachingPopoverCarouselNav");
const _renderTeachingPopoverCarouselNav = require("./renderTeachingPopoverCarouselNav");
const _useTeachingPopoverCarouselNavStylesstyles = require("./useTeachingPopoverCarouselNavStyles.styles");
const TeachingPopoverCarouselNav = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useTeachingPopoverCarouselNav.useTeachingPopoverCarouselNav_unstable)(props, ref);
(0, _useTeachingPopoverCarouselNavStylesstyles.useTeachingPopoverCarouselNavStyles_unstable)(state);
return (0, _renderTeachingPopoverCarouselNav.renderTeachingPopoverCarouselNav_unstable)(state);
});
TeachingPopoverCarouselNav.displayName = 'TeachingPopoverCarouselNav';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useTeachingPopoverCarouselNav_unstable } from './useTeachingPopoverCarouselNav';\nimport { renderTeachingPopoverCarouselNav_unstable } from './renderTeachingPopoverCarouselNav';\nimport { useTeachingPopoverCarouselNavStyles_unstable } from './useTeachingPopoverCarouselNavStyles.styles';\nimport type { TeachingPopoverCarouselNavProps } from './TeachingPopoverCarouselNav.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * Define a styled TeachingPopoverCarouselNav, using the `useTeachingPopoverCarouselNav_unstable` and `useTeachingPopoverCarouselNavStyles_unstable`\n * hooks.\n *\n * TeachingPopoverCarouselNav provides an index-based pagination list to jump to any page within the carousel.\n */\nexport const TeachingPopoverCarouselNav: ForwardRefComponent<TeachingPopoverCarouselNavProps> = React.forwardRef(\n (props, ref) => {\n const state = useTeachingPopoverCarouselNav_unstable(props, ref);\n\n useTeachingPopoverCarouselNavStyles_unstable(state);\n\n return renderTeachingPopoverCarouselNav_unstable(state);\n },\n);\n\nTeachingPopoverCarouselNav.displayName = 'TeachingPopoverCarouselNav';\n"],"names":["TeachingPopoverCarouselNav","React","forwardRef","props","ref","state","useTeachingPopoverCarouselNav_unstable","useTeachingPopoverCarouselNavStyles_unstable","renderTeachingPopoverCarouselNav_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAaaA;;;eAAAA;;;;iEAbU;+CACgC;kDACG;2DACG;AAUtD,MAAMA,6BAAAA,WAAAA,GAAmFC,OAAMC,UAAU,CAC9G,CAACC,OAAOC;IACN,MAAMC,QAAQC,IAAAA,qEAAAA,EAAuCH,OAAOC;IAE5DG,IAAAA,uFAAAA,EAA6CF;IAE7C,OAAOG,IAAAA,2EAAAA,EAA0CH;AACnD;AAGFL,2BAA2BS,WAAW,GAAG"}
@@ -0,0 +1,6 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselNav/TeachingPopoverCarouselNav.types.ts"],"sourcesContent":["import * as React from 'react';\nimport { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type TeachingPopoverCarouselNavSlots = {\n /**\n * The element wrapping the carousel pagination. By default this is a div,\n * it may contain icons or text depending on TeachingPopoverCarouselNavStyle\n */\n root: NonNullable<Slot<'div'>>;\n};\n\nexport type NavButtonRenderFunction = (value: string) => React.ReactNode;\n\nexport type TeachingPopoverCarouselNavState = ComponentState<TeachingPopoverCarouselNavSlots> & {\n values: string[];\n\n renderNavButton: NavButtonRenderFunction;\n};\n\nexport type TeachingPopoverCarouselNavProps = Omit<\n ComponentProps<Partial<TeachingPopoverCarouselNavSlots>>,\n 'children'\n> & {\n children: NavButtonRenderFunction;\n};\n"],"names":[],"rangeMappings":";;;;;","mappings":";;;;;iEAAuB"}
@@ -0,0 +1,31 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
function _export(target, all) {
for(var name in all)Object.defineProperty(target, name, {
enumerable: true,
get: all[name]
});
}
_export(exports, {
TeachingPopoverCarouselNav: function() {
return _TeachingPopoverCarouselNav.TeachingPopoverCarouselNav;
},
renderTeachingPopoverCarouselNav_unstable: function() {
return _renderTeachingPopoverCarouselNav.renderTeachingPopoverCarouselNav_unstable;
},
teachingPopoverCarouselNavClassNames: function() {
return _useTeachingPopoverCarouselNavStylesstyles.teachingPopoverCarouselNavClassNames;
},
useTeachingPopoverCarouselNavStyles_unstable: function() {
return _useTeachingPopoverCarouselNavStylesstyles.useTeachingPopoverCarouselNavStyles_unstable;
},
useTeachingPopoverCarouselNav_unstable: function() {
return _useTeachingPopoverCarouselNav.useTeachingPopoverCarouselNav_unstable;
}
});
const _TeachingPopoverCarouselNav = require("./TeachingPopoverCarouselNav");
const _renderTeachingPopoverCarouselNav = require("./renderTeachingPopoverCarouselNav");
const _useTeachingPopoverCarouselNav = require("./useTeachingPopoverCarouselNav");
const _useTeachingPopoverCarouselNavStylesstyles = require("./useTeachingPopoverCarouselNavStyles.styles");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/TeachingPopoverCarouselNav/index.ts"],"sourcesContent":["export { TeachingPopoverCarouselNav } from './TeachingPopoverCarouselNav';\nexport type {\n NavButtonRenderFunction,\n TeachingPopoverCarouselNavProps,\n TeachingPopoverCarouselNavSlots,\n TeachingPopoverCarouselNavState,\n} from './TeachingPopoverCarouselNav.types';\nexport { renderTeachingPopoverCarouselNav_unstable } from './renderTeachingPopoverCarouselNav';\nexport { useTeachingPopoverCarouselNav_unstable } from './useTeachingPopoverCarouselNav';\nexport {\n teachingPopoverCarouselNavClassNames,\n useTeachingPopoverCarouselNavStyles_unstable,\n} from './useTeachingPopoverCarouselNavStyles.styles';\n"],"names":["TeachingPopoverCarouselNav","renderTeachingPopoverCarouselNav_unstable","teachingPopoverCarouselNavClassNames","useTeachingPopoverCarouselNavStyles_unstable","useTeachingPopoverCarouselNav_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,0BAA0B;eAA1BA,sDAA0B;;IAO1BC,yCAAyC;eAAzCA,2EAAyC;;IAGhDC,oCAAoC;eAApCA,+EAAoC;;IACpCC,4CAA4C;eAA5CA,uFAA4C;;IAHrCC,sCAAsC;eAAtCA,qEAAsC;;;4CARJ;kDAOe;+CACH;2DAIhD"}

Some files were not shown because too many files have changed in this diff Show More