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,23 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "DrawerHeaderTitle", {
enumerable: true,
get: function() {
return DrawerHeaderTitle;
}
});
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
const _reactsharedcontexts = require("@fluentui/react-shared-contexts");
const _useDrawerHeaderTitle = require("./useDrawerHeaderTitle");
const _renderDrawerHeaderTitle = require("./renderDrawerHeaderTitle");
const _useDrawerHeaderTitleStylesstyles = require("./useDrawerHeaderTitleStyles.styles");
const DrawerHeaderTitle = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
const state = (0, _useDrawerHeaderTitle.useDrawerHeaderTitle_unstable)(props, ref);
(0, _useDrawerHeaderTitleStylesstyles.useDrawerHeaderTitleStyles_unstable)(state);
(0, _reactsharedcontexts.useCustomStyleHook_unstable)('useDrawerHeaderTitleStyles_unstable')(state);
return (0, _renderDrawerHeaderTitle.renderDrawerHeaderTitle_unstable)(state);
});
DrawerHeaderTitle.displayName = 'DrawerHeaderTitle';
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/DrawerHeaderTitle/DrawerHeaderTitle.tsx"],"sourcesContent":["import * as React from 'react';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n\nimport { useDrawerHeaderTitle_unstable } from './useDrawerHeaderTitle';\nimport { renderDrawerHeaderTitle_unstable } from './renderDrawerHeaderTitle';\nimport { useDrawerHeaderTitleStyles_unstable } from './useDrawerHeaderTitleStyles.styles';\nimport type { DrawerHeaderTitleProps } from './DrawerHeaderTitle.types';\n\n/**\n * DrawerHeader provides a structured header for the drawer component.\n */\nexport const DrawerHeaderTitle: ForwardRefComponent<DrawerHeaderTitleProps> = React.forwardRef((props, ref) => {\n const state = useDrawerHeaderTitle_unstable(props, ref);\n\n useDrawerHeaderTitleStyles_unstable(state);\n useCustomStyleHook_unstable('useDrawerHeaderTitleStyles_unstable')(state);\n\n return renderDrawerHeaderTitle_unstable(state);\n});\n\nDrawerHeaderTitle.displayName = 'DrawerHeaderTitle';\n"],"names":["DrawerHeaderTitle","React","forwardRef","props","ref","state","useDrawerHeaderTitle_unstable","useDrawerHeaderTitleStyles_unstable","useCustomStyleHook_unstable","renderDrawerHeaderTitle_unstable","displayName"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAYaA;;;eAAAA;;;;iEAZU;qCAEqB;sCAEE;yCACG;kDACG;AAM7C,MAAMA,oBAAAA,WAAAA,GAAiEC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IACrG,MAAMC,QAAQC,IAAAA,mDAAAA,EAA8BH,OAAOC;IAEnDG,IAAAA,qEAAAA,EAAoCF;IACpCG,IAAAA,gDAAAA,EAA4B,uCAAuCH;IAEnE,OAAOI,IAAAA,yDAAAA,EAAiCJ;AAC1C;AAEAL,kBAAkBU,WAAW,GAAG"}
@@ -0,0 +1,6 @@
/**
* State used in rendering DrawerHeaderTitle
*/ "use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/DrawerHeaderTitle/DrawerHeaderTitle.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type DrawerHeaderTitleSlots = {\n root: Slot<'div'>;\n\n /**\n * By default this is a h2, but can be any heading or div.\n * If `div` is provided do not forget to also provide proper `role=\"heading\"` and `aria-level` attributes\n */\n heading?: Slot<'h2', 'h1' | 'h3' | 'h4' | 'h5' | 'h6' | 'div'>;\n\n /**\n * Action slot for the close button\n */\n action?: Slot<'div'>;\n};\n\n/**\n * DrawerHeaderTitle Props\n */\nexport type DrawerHeaderTitleProps = ComponentProps<DrawerHeaderTitleSlots>;\n\n/**\n * State used in rendering DrawerHeaderTitle\n */\nexport type DrawerHeaderTitleState = ComponentState<DrawerHeaderTitleSlots>;\n"],"names":[],"rangeMappings":";;","mappings":"AAsBA;;CAEC"}
@@ -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, {
DrawerHeaderTitle: function() {
return _DrawerHeaderTitle.DrawerHeaderTitle;
},
drawerHeaderTitleClassNames: function() {
return _useDrawerHeaderTitleStylesstyles.drawerHeaderTitleClassNames;
},
renderDrawerHeaderTitle_unstable: function() {
return _renderDrawerHeaderTitle.renderDrawerHeaderTitle_unstable;
},
useDrawerHeaderTitleStyles_unstable: function() {
return _useDrawerHeaderTitleStylesstyles.useDrawerHeaderTitleStyles_unstable;
},
useDrawerHeaderTitle_unstable: function() {
return _useDrawerHeaderTitle.useDrawerHeaderTitle_unstable;
}
});
const _DrawerHeaderTitle = require("./DrawerHeaderTitle");
const _renderDrawerHeaderTitle = require("./renderDrawerHeaderTitle");
const _useDrawerHeaderTitle = require("./useDrawerHeaderTitle");
const _useDrawerHeaderTitleStylesstyles = require("./useDrawerHeaderTitleStyles.styles");
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/DrawerHeaderTitle/index.ts"],"sourcesContent":["export { DrawerHeaderTitle } from './DrawerHeaderTitle';\nexport type { DrawerHeaderTitleProps, DrawerHeaderTitleSlots, DrawerHeaderTitleState } from './DrawerHeaderTitle.types';\nexport { renderDrawerHeaderTitle_unstable } from './renderDrawerHeaderTitle';\nexport { useDrawerHeaderTitle_unstable } from './useDrawerHeaderTitle';\nexport { drawerHeaderTitleClassNames, useDrawerHeaderTitleStyles_unstable } from './useDrawerHeaderTitleStyles.styles';\n"],"names":["DrawerHeaderTitle","drawerHeaderTitleClassNames","renderDrawerHeaderTitle_unstable","useDrawerHeaderTitleStyles_unstable","useDrawerHeaderTitle_unstable"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAASA,iBAAiB;eAAjBA,oCAAiB;;IAIjBC,2BAA2B;eAA3BA,6DAA2B;;IAF3BC,gCAAgC;eAAhCA,yDAAgC;;IAEHC,mCAAmC;eAAnCA,qEAAmC;;IADhEC,6BAA6B;eAA7BA,mDAA6B;;;mCAHJ;yCAEe;sCACH;kDACmC"}
@@ -0,0 +1,21 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "renderDrawerHeaderTitle_unstable", {
enumerable: true,
get: function() {
return renderDrawerHeaderTitle_unstable;
}
});
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
const _reactutilities = require("@fluentui/react-utilities");
const renderDrawerHeaderTitle_unstable = (state)=>{
(0, _reactutilities.assertSlots)(state);
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(state.root, {
children: [
state.heading && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.heading, {}),
state.action && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.action, {})
]
});
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/DrawerHeaderTitle/renderDrawerHeaderTitle.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\nimport { assertSlots } from '@fluentui/react-utilities';\n\nimport type { DrawerHeaderTitleState, DrawerHeaderTitleSlots } from './DrawerHeaderTitle.types';\n\n/**\n * Render the final JSX of DrawerHeaderTitle\n */\nexport const renderDrawerHeaderTitle_unstable = (state: DrawerHeaderTitleState) => {\n assertSlots<DrawerHeaderTitleSlots>(state);\n\n return (\n <state.root>\n {state.heading && <state.heading />}\n {state.action && <state.action />}\n </state.root>\n );\n};\n"],"names":["renderDrawerHeaderTitle_unstable","state","assertSlots","_jsxs","root","heading","_jsx","action"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BASaA;;;eAAAA;;;4BARb;gCAC4B;AAOrB,MAAMA,mCAAmC,CAACC;IAC/CC,IAAAA,2BAAAA,EAAoCD;IAEpC,OAAA,WAAA,GACEE,IAAAA,gBAAA,EAACF,MAAMG,IAAI,EAAA;;YACRH,MAAMI,OAAO,IAAA,WAAA,GAAIC,IAAAA,eAAA,EAACL,MAAMI,OAAO,EAAA,CAAA;YAC/BJ,MAAMM,MAAM,IAAA,WAAA,GAAID,IAAAA,eAAA,EAACL,MAAMM,MAAM,EAAA,CAAA;;;AAGpC"}
@@ -0,0 +1,42 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
Object.defineProperty(exports, "useDrawerHeaderTitle_unstable", {
enumerable: true,
get: function() {
return useDrawerHeaderTitle_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 _reactdialog = require("@fluentui/react-dialog");
const useDrawerHeaderTitle_unstable = (props, ref)=>{
const { children, heading } = props;
const headingId = (0, _reactdialog.useDialogContext_unstable)((ctx)=>ctx.dialogTitleId);
return {
components: {
root: 'div',
heading: 'h2',
action: 'div'
},
root: _reactutilities.slot.always((0, _reactutilities.getIntrinsicElementProps)('div', {
ref,
...props
}), {
elementType: 'div'
}),
heading: _reactutilities.slot.optional(heading, {
defaultProps: {
id: headingId,
children
},
renderByDefault: true,
elementType: 'h2'
}),
action: _reactutilities.slot.optional(props.action, {
elementType: 'div'
})
};
};
@@ -0,0 +1 @@
{"version":3,"sources":["../src/components/DrawerHeaderTitle/useDrawerHeaderTitle.ts"],"sourcesContent":["import * as React from 'react';\nimport { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';\nimport { useDialogContext_unstable } from '@fluentui/react-dialog';\n\nimport type { DrawerHeaderTitleProps, DrawerHeaderTitleState } from './DrawerHeaderTitle.types';\n\n/**\n * Create the state required to render DrawerHeaderTitle.\n *\n * The returned state can be modified with hooks such as useDrawerHeaderTitleStyles_unstable,\n * before being passed to renderDrawerHeaderTitle_unstable.\n *\n * @param props - props from this instance of DrawerHeaderTitle\n * @param ref - reference to root HTMLElement of DrawerHeaderTitle\n */\nexport const useDrawerHeaderTitle_unstable = (\n props: DrawerHeaderTitleProps,\n ref: React.Ref<HTMLDivElement>,\n): DrawerHeaderTitleState => {\n const { children, heading } = props;\n const headingId = useDialogContext_unstable(ctx => ctx.dialogTitleId);\n\n return {\n components: {\n root: 'div',\n heading: 'h2',\n action: 'div',\n },\n\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n heading: slot.optional(heading, {\n defaultProps: {\n id: headingId,\n children,\n },\n renderByDefault: true,\n elementType: 'h2',\n }),\n action: slot.optional(props.action, {\n elementType: 'div',\n }),\n };\n};\n"],"names":["useDrawerHeaderTitle_unstable","props","ref","children","heading","headingId","useDialogContext_unstable","ctx","dialogTitleId","components","root","action","slot","always","getIntrinsicElementProps","elementType","optional","defaultProps","id","renderByDefault"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;+BAeaA;;;eAAAA;;;;iEAfU;gCACwB;6BACL;AAanC,MAAMA,gCAAgC,CAC3CC,OACAC;IAEA,MAAM,EAAEC,QAAQ,EAAEC,OAAO,EAAE,GAAGH;IAC9B,MAAMI,YAAYC,IAAAA,sCAAAA,EAA0BC,CAAAA,MAAOA,IAAIC,aAAa;IAEpE,OAAO;QACLC,YAAY;YACVC,MAAM;YACNN,SAAS;YACTO,QAAQ;QACV;QAEAD,MAAME,oBAAAA,CAAKC,MAAM,CACfC,IAAAA,wCAAAA,EAAyB,OAAO;YAC9BZ;YACA,GAAGD,KAAK;QACV,IACA;YAAEc,aAAa;QAAM;QAEvBX,SAASQ,oBAAAA,CAAKI,QAAQ,CAACZ,SAAS;YAC9Ba,cAAc;gBACZC,IAAIb;gBACJF;YACF;YACAgB,iBAAiB;YACjBJ,aAAa;QACf;QACAJ,QAAQC,oBAAAA,CAAKI,QAAQ,CAACf,MAAMU,MAAM,EAAE;YAClCI,aAAa;QACf;IACF;AACF"}
@@ -0,0 +1,71 @@
"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, {
drawerHeaderTitleClassNames: function() {
return drawerHeaderTitleClassNames;
},
useDrawerHeaderTitleStyles_unstable: function() {
return useDrawerHeaderTitleStyles_unstable;
}
});
const _react = require("@griffel/react");
const _reactdialog = require("@fluentui/react-dialog");
const drawerHeaderTitleClassNames = {
root: 'fui-DrawerHeaderTitle',
heading: 'fui-DrawerHeaderTitle__heading',
action: 'fui-DrawerHeaderTitle__action'
};
/**
* Styles for the root slot
*/ const useStyles = /*#__PURE__*/ (0, _react.__styles)({
root: {
mc9l5x: "f22iagw",
Brf1p80: "f1869bpl",
Bt984gj: "f122n59",
i8kkvl: "fsnqrgy"
},
action: {
t21cq0: [
"faqnl2i",
"fd75udd"
]
}
}, {
d: [
".f22iagw{display:flex;}",
".f1869bpl{justify-content:space-between;}",
".f122n59{align-items:center;}",
".fsnqrgy{column-gap:var(--spacingHorizontalS);}",
".faqnl2i{margin-right:calc(var(--spacingHorizontalS) * -1);}",
".fd75udd{margin-left:calc(var(--spacingHorizontalS) * -1);}"
]
});
const useDrawerHeaderTitleStyles_unstable = (state)=>{
'use no memo';
const styles = useStyles();
const { heading: root = {}, action, components } = state;
(0, _reactdialog.useDialogTitleStyles_unstable)({
components: {
root: components.heading,
action: components.action
},
root,
action
});
state.root.className = (0, _react.mergeClasses)(drawerHeaderTitleClassNames.root, styles.root, state.root.className);
if (state.heading) {
state.heading.className = (0, _react.mergeClasses)(drawerHeaderTitleClassNames.heading, state.heading.className);
}
if (state.action) {
state.action.className = (0, _react.mergeClasses)(drawerHeaderTitleClassNames.action, styles.action, state.action.className);
}
return state;
};
@@ -0,0 +1 @@
{"version":3,"sources":["useDrawerHeaderTitleStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses } from '@griffel/react';\nimport { useDialogTitleStyles_unstable } from '@fluentui/react-dialog';\nimport { tokens } from '@fluentui/react-theme';\nexport const drawerHeaderTitleClassNames = {\n root: 'fui-DrawerHeaderTitle',\n heading: 'fui-DrawerHeaderTitle__heading',\n action: 'fui-DrawerHeaderTitle__action'\n};\n/**\n * Styles for the root slot\n */ const useStyles = makeStyles({\n root: {\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n columnGap: tokens.spacingHorizontalS\n },\n action: {\n marginRight: `calc(${tokens.spacingHorizontalS} * -1)`\n }\n});\n/**\n * Apply styling to the DrawerHeaderTitle slots based on the state\n */ export const useDrawerHeaderTitleStyles_unstable = (state)=>{\n 'use no memo';\n const styles = useStyles();\n const { heading: root = {}, action, components } = state;\n useDialogTitleStyles_unstable({\n components: {\n root: components.heading,\n action: components.action\n },\n root,\n action\n });\n state.root.className = mergeClasses(drawerHeaderTitleClassNames.root, styles.root, state.root.className);\n if (state.heading) {\n state.heading.className = mergeClasses(drawerHeaderTitleClassNames.heading, state.heading.className);\n }\n if (state.action) {\n state.action.className = mergeClasses(drawerHeaderTitleClassNames.action, styles.action, state.action.className);\n }\n return state;\n};\n"],"names":["drawerHeaderTitleClassNames","useDrawerHeaderTitleStyles_unstable","root","heading","action","useStyles","__styles","mc9l5x","Brf1p80","Bt984gj","i8kkvl","t21cq0","d","state","styles","components","useDialogTitleStyles_unstable","className","mergeClasses"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":";;;;;;;;;;;IAGaA,2BAA2B;eAA3BA;;IAoBIC,mCAAmC;eAAnCA;;;uBAvBwB;6BACK;AAEvC,MAAMD,8BAA8B;IACvCE,MAAM;IACNC,SAAS;IACTC,QAAQ;AACZ;AACA;;CAEA,GAAI,MAAMC,YAAS,WAAA,GAAGC,IAAAA,eAAA,EAAA;IAAAJ,MAAA;QAAAK,QAAA;QAAAC,SAAA;QAAAC,SAAA;QAAAC,QAAA;IAAA;IAAAN,QAAA;QAAAO,QAAA;YAAA;YAAA;SAAA;IAAA;AAAA,GAAA;IAAAC,GAAA;QAAA;QAAA;QAAA;QAAA;QAAA;QAAA;KAAA;AAAA;AAaX,MAAMX,sCAAuCY,CAAAA;IACpD;IACA,MAAMC,SAAST;IACf,MAAM,EAAEF,SAASD,OAAO,CAAC,CAAC,EAAEE,MAAM,EAAEW,UAAAA,EAAY,GAAGF;IACnDG,IAAAA,0CAA6B,EAAC;QAC1BD,YAAY;YACRb,MAAMa,WAAWZ,OAAO;YACxBC,QAAQW,WAAWX,MAAAA;QACvB;QACAF;QACAE;IACJ;IACAS,MAAMX,IAAI,CAACe,SAAS,GAAGC,IAAAA,mBAAY,EAAClB,4BAA4BE,IAAI,EAAEY,OAAOZ,IAAI,EAAEW,MAAMX,IAAI,CAACe,SAAS;IACvG,IAAIJ,MAAMV,OAAO,EAAE;QACfU,MAAMV,OAAO,CAACc,SAAS,GAAGC,IAAAA,mBAAY,EAAClB,4BAA4BG,OAAO,EAAEU,MAAMV,OAAO,CAACc,SAAS;IACvG;IACA,IAAIJ,MAAMT,MAAM,EAAE;QACdS,MAAMT,MAAM,CAACa,SAAS,GAAGC,IAAAA,mBAAY,EAAClB,4BAA4BI,MAAM,EAAEU,OAAOV,MAAM,EAAES,MAAMT,MAAM,CAACa,SAAS;IACnH;IACA,OAAOJ;AACX"}