first commit

This commit is contained in:
Stefan Hacker
2026-04-03 09:38:48 +02:00
commit 37ad745546
47450 changed files with 3120798 additions and 0 deletions
@@ -0,0 +1,10 @@
import * as React from 'react';
import type { IAnnouncedProps } from './Announced.types';
import type { JSXElement } from '@fluentui/utilities';
/**
* {@docCategory Announced}
*/
export declare class AnnouncedBase extends React.Component<IAnnouncedProps> {
static defaultProps: Partial<IAnnouncedProps>;
render(): JSXElement;
}
@@ -0,0 +1,26 @@
import { __assign, __extends } from "tslib";
import * as React from 'react';
import { DelayedRender, classNamesFunction, getNativeProps, divProperties } from '../../Utilities';
var getClassNames = classNamesFunction();
/**
* {@docCategory Announced}
*/
var AnnouncedBase = /** @class */ (function (_super) {
__extends(AnnouncedBase, _super);
function AnnouncedBase() {
return _super !== null && _super.apply(this, arguments) || this;
}
AnnouncedBase.prototype.render = function () {
var _a = this.props, message = _a.message, styles = _a.styles, _b = _a.as, Root = _b === void 0 ? 'div' : _b, className = _a.className;
var classNames = getClassNames(styles, { className: className });
return (React.createElement(Root, __assign({ role: "status", className: classNames.root }, getNativeProps(this.props, divProperties, ['className'])),
React.createElement(DelayedRender, null,
React.createElement("div", { className: classNames.screenReaderText }, message))));
};
AnnouncedBase.defaultProps = {
'aria-live': 'polite',
};
return AnnouncedBase;
}(React.Component));
export { AnnouncedBase };
//# sourceMappingURL=Announced.base.js.map
@@ -0,0 +1 @@
{"version":3,"file":"Announced.base.js","sourceRoot":"../src/","sources":["components/Announced/Announced.base.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAKnG,IAAM,aAAa,GAAG,kBAAkB,EAAwB,CAAC;AAEjE;;GAEG;AACH;IAAmC,iCAAgC;IAAnE;;IAkBA,CAAC;IAbQ,8BAAM,GAAb;QACQ,IAAA,KAAmD,IAAI,CAAC,KAAK,EAA3D,OAAO,aAAA,EAAE,MAAM,YAAA,EAAE,UAAgB,EAAZ,IAAI,mBAAG,KAAK,KAAA,EAAE,SAAS,eAAe,CAAC;QAEpE,IAAM,UAAU,GAAG,aAAa,CAAC,MAAM,EAAE,EAAE,SAAS,WAAA,EAAE,CAAC,CAAC;QAExD,OAAO,CACL,oBAAC,IAAI,aAAC,IAAI,EAAC,QAAQ,EAAC,SAAS,EAAE,UAAU,CAAC,IAAI,IAAM,cAAc,CAAC,IAAI,CAAC,KAAK,EAAE,aAAa,EAAE,CAAC,WAAW,CAAC,CAAC;YAC1G,oBAAC,aAAa;gBACZ,6BAAK,SAAS,EAAE,UAAU,CAAC,gBAAgB,IAAG,OAAO,CAAO,CAC9C,CACX,CACR,CAAC;IACJ,CAAC;IAhBa,0BAAY,GAA6B;QACrD,WAAW,EAAE,QAAQ;KACtB,CAAC;IAeJ,oBAAC;CAAA,AAlBD,CAAmC,KAAK,CAAC,SAAS,GAkBjD;SAlBY,aAAa","sourcesContent":["import * as React from 'react';\nimport { DelayedRender, classNamesFunction, getNativeProps, divProperties } from '../../Utilities';\nimport type { IAnnouncedProps, IAnnouncedStyles } from './Announced.types';\n\nimport type { JSXElement } from '@fluentui/utilities';\n\nconst getClassNames = classNamesFunction<{}, IAnnouncedStyles>();\n\n/**\n * {@docCategory Announced}\n */\nexport class AnnouncedBase extends React.Component<IAnnouncedProps> {\n public static defaultProps: Partial<IAnnouncedProps> = {\n 'aria-live': 'polite',\n };\n\n public render(): JSXElement {\n const { message, styles, as: Root = 'div', className } = this.props;\n\n const classNames = getClassNames(styles, { className });\n\n return (\n <Root role=\"status\" className={classNames.root} {...getNativeProps(this.props, divProperties, ['className'])}>\n <DelayedRender>\n <div className={classNames.screenReaderText}>{message}</div>\n </DelayedRender>\n </Root>\n );\n }\n}\n"]}
+3
View File
@@ -0,0 +1,3 @@
import * as React from 'react';
import type { IAnnouncedProps } from './Announced.types';
export declare const Announced: React.FunctionComponent<IAnnouncedProps>;
+5
View File
@@ -0,0 +1,5 @@
import { styled } from '../../Utilities';
import { AnnouncedBase } from './Announced.base';
import { getStyles } from './Announced.styles';
export var Announced = styled(AnnouncedBase, getStyles, undefined, { scope: 'Announced' });
//# sourceMappingURL=Announced.js.map
@@ -0,0 +1 @@
{"version":3,"file":"Announced.js","sourceRoot":"../src/","sources":["components/Announced/Announced.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAG/C,MAAM,CAAC,IAAM,SAAS,GAA6C,MAAM,CACvE,aAAa,EACb,SAAS,EACT,SAAS,EACT,EAAE,KAAK,EAAE,WAAW,EAAE,CACvB,CAAC","sourcesContent":["import * as React from 'react';\nimport { styled } from '../../Utilities';\nimport { AnnouncedBase } from './Announced.base';\nimport { getStyles } from './Announced.styles';\nimport type { IAnnouncedProps, IAnnouncedStyles } from './Announced.types';\n\nexport const Announced: React.FunctionComponent<IAnnouncedProps> = styled<IAnnouncedProps, {}, IAnnouncedStyles>(\n AnnouncedBase,\n getStyles,\n undefined,\n { scope: 'Announced' },\n);\n"]}
@@ -0,0 +1,3 @@
import type { IStyleFunction } from '../../Utilities';
import type { IAnnouncedStyles, IAnnouncedStyleProps } from './Announced.types';
export declare const getStyles: IStyleFunction<IAnnouncedStyleProps, IAnnouncedStyles>;
@@ -0,0 +1,8 @@
import { hiddenContentStyle } from '../../Styling';
export var getStyles = function (props) {
return {
root: props.className,
screenReaderText: hiddenContentStyle,
};
};
//# sourceMappingURL=Announced.styles.js.map
@@ -0,0 +1 @@
{"version":3,"file":"Announced.styles.js","sourceRoot":"../src/","sources":["components/Announced/Announced.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAInD,MAAM,CAAC,IAAM,SAAS,GAA2D,UAAA,KAAK;IACpF,OAAO;QACL,IAAI,EAAE,KAAK,CAAC,SAAS;QACrB,gBAAgB,EAAE,kBAAkB;KACrC,CAAC;AACJ,CAAC,CAAC","sourcesContent":["import { hiddenContentStyle } from '../../Styling';\nimport type { IStyleFunction } from '../../Utilities';\nimport type { IAnnouncedStyles, IAnnouncedStyleProps } from './Announced.types';\n\nexport const getStyles: IStyleFunction<IAnnouncedStyleProps, IAnnouncedStyles> = props => {\n return {\n root: props.className,\n screenReaderText: hiddenContentStyle,\n };\n};\n"]}
@@ -0,0 +1,43 @@
import * as React from 'react';
import { AnnouncedBase } from './Announced.base';
import type { IStyle } from '../../Styling';
import type { IReactProps, IStyleFunctionOrObject } from '../../Utilities';
/**
* {@docCategory Announced}
*/
export interface IAnnouncedProps extends IReactProps<AnnouncedBase>, React.HTMLAttributes<HTMLDivElement> {
/**
* The status message the screen reader should announce.
*/
message?: string;
/**
* Priority with which the screen reader should treat updates to this region.
* @default 'polite'
*/
'aria-live'?: 'off' | 'polite' | 'assertive';
/**
* Optionally render the root of this component as another component type or primitive.
* The custom type **must** preserve any children or native props passed in.
* @default 'div'
*/
as?: React.ElementType;
/** Call to provide customized styling that will layer on top of the variant rules. */
styles?: IStyleFunctionOrObject<{}, IAnnouncedStyles>;
}
/**
* {@docCategory Announced}
*/
export type IAnnouncedStyleProps = Pick<IAnnouncedProps, 'className'>;
/**
* {@docCategory Announced}
*/
export interface IAnnouncedStyles {
/**
* Style override for the root element.
*/
root: IStyle;
/**
* Style override for the screen reader text.
*/
screenReaderText: IStyle;
}
@@ -0,0 +1,2 @@
export {};
//# sourceMappingURL=Announced.types.js.map
@@ -0,0 +1 @@
{"version":3,"file":"Announced.types.js","sourceRoot":"../src/","sources":["components/Announced/Announced.types.ts"],"names":[],"mappings":"","sourcesContent":["import * as React from 'react';\nimport { AnnouncedBase } from './Announced.base';\nimport type { IStyle } from '../../Styling';\nimport type { IReactProps, IStyleFunctionOrObject } from '../../Utilities';\n\n/**\n * {@docCategory Announced}\n */\nexport interface IAnnouncedProps extends IReactProps<AnnouncedBase>, React.HTMLAttributes<HTMLDivElement> {\n /**\n * The status message the screen reader should announce.\n */\n message?: string;\n\n /**\n * Priority with which the screen reader should treat updates to this region.\n * @default 'polite'\n */\n 'aria-live'?: 'off' | 'polite' | 'assertive';\n\n /**\n * Optionally render the root of this component as another component type or primitive.\n * The custom type **must** preserve any children or native props passed in.\n * @default 'div'\n */\n as?: React.ElementType;\n\n /** Call to provide customized styling that will layer on top of the variant rules. */\n styles?: IStyleFunctionOrObject<{}, IAnnouncedStyles>;\n}\n\n/**\n * {@docCategory Announced}\n */\nexport type IAnnouncedStyleProps = Pick<IAnnouncedProps, 'className'>;\n\n/**\n * {@docCategory Announced}\n */\nexport interface IAnnouncedStyles {\n /**\n * Style override for the root element.\n */\n root: IStyle;\n\n /**\n * Style override for the screen reader text.\n */\n screenReaderText: IStyle;\n}\n"]}
+3
View File
@@ -0,0 +1,3 @@
export * from './Announced';
export * from './Announced.base';
export * from './Announced.types';
+4
View File
@@ -0,0 +1,4 @@
export * from './Announced';
export * from './Announced.base';
export * from './Announced.types';
//# sourceMappingURL=index.js.map
+1
View File
@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/Announced/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC","sourcesContent":["export * from './Announced';\nexport * from './Announced.base';\nexport * from './Announced.types';\n"]}