fluentui/packages/style-utilities/etc/style-utilities.api.md

369 строки
11 KiB
Markdown
Исходник Постоянная ссылка Обычный вид История

## API Report File for "@fluentui/style-utilities"
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
```ts
import { AnimationStyles } from '@fluentui/theme';
import { AnimationVariables } from '@fluentui/theme';
import { concatStyleSets } from '@fluentui/merge-styles';
import { concatStyleSetsWithProps } from '@fluentui/merge-styles';
import { createFontStyles } from '@fluentui/theme';
import { createTheme } from '@fluentui/theme';
import { DefaultEffects } from '@fluentui/theme';
import { DefaultFontStyles } from '@fluentui/theme';
import { DefaultPalette } from '@fluentui/theme';
import { fontFace } from '@fluentui/merge-styles';
import { FontSizes } from '@fluentui/theme';
import { FontWeights } from '@fluentui/theme';
import { IAnimationStyles } from '@fluentui/theme';
import { IAnimationVariables } from '@fluentui/theme';
import { IconFontSizes } from '@fluentui/theme';
import { ICSPSettings } from '@fluentui/merge-styles';
import type { ICustomizerContext } from '@fluentui/utilities';
import { IEffects } from '@fluentui/theme';
import { IFontFace } from '@fluentui/merge-styles';
import { IFontStyles } from '@fluentui/theme';
import { IFontWeight } from '@fluentui/merge-styles';
import { InjectionMode } from '@fluentui/merge-styles';
import { IPalette } from '@fluentui/theme';
import { IPartialTheme } from '@fluentui/theme';
import { IProcessedStyleSet } from '@fluentui/merge-styles';
import { IRawStyle } from '@fluentui/merge-styles';
import { IScheme } from '@fluentui/theme';
import { ISchemeNames } from '@fluentui/theme';
import { ISemanticColors } from '@fluentui/theme';
import { ISemanticTextColors } from '@fluentui/theme';
import { ISpacing } from '@fluentui/theme';
import { IStyle } from '@fluentui/merge-styles';
import { IStyleSet } from '@fluentui/merge-styles';
import { IStyleSetBase } from '@fluentui/merge-styles';
import { IStyleSheetConfig } from '@fluentui/merge-styles';
import { ITheme } from '@fluentui/theme';
import { keyframes } from '@fluentui/merge-styles';
import { mergeStyles } from '@fluentui/merge-styles';
import { mergeStyleSets } from '@fluentui/merge-styles';
import { registerDefaultFontFaces } from '@fluentui/theme';
import { ShadowConfig } from '@fluentui/merge-styles';
import { Stylesheet } from '@fluentui/merge-styles';
// @public (undocumented)
export const AnimationClassNames: {
[key in keyof IAnimationStyles]?: string;
};
export { AnimationStyles }
export { AnimationVariables }
// @public
export function buildClassMap<T extends Object>(styles: T): {
[key in keyof T]?: string;
};
// Warning: (ae-forgotten-export) The symbol "IColorClassNames" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export const ColorClassNames: IColorClassNames;
export { concatStyleSets }
export { concatStyleSetsWithProps }
export { createFontStyles }
export { createTheme }
export { DefaultEffects }
export { DefaultFontStyles }
export { DefaultPalette }
// @public @deprecated (undocumented)
export const EdgeChromiumHighContrastSelector = "@media screen and (-ms-high-contrast: active), screen and (forced-colors: active)";
// @public (undocumented)
export const FLUENT_CDN_BASE_URL = "https://res.cdn.office.net/files/fabric-cdn-prod_20241029.001";
// @public
export function focusClear(): IRawStyle;
// @public (undocumented)
export const FontClassNames: {
[key in keyof IFontStyles]?: string;
};
export { fontFace }
export { FontSizes }
export { FontWeights }
// @public @deprecated
export function getEdgeChromiumNoHighContrastAdjustSelector(): {
[EdgeChromiumHighContrastSelector]: IRawStyle;
};
// @public
export function getFadedOverflowStyle(theme: ITheme, color?: keyof ISemanticColors | keyof IPalette, direction?: 'horizontal' | 'vertical', width?: string | number, height?: string | number): IRawStyle;
// @public
export function getFocusOutlineStyle(theme: ITheme, inset?: number, width?: number, color?: string): IRawStyle;
// @public
export function getFocusStyle(theme: ITheme, options?: IGetFocusStylesOptions): IRawStyle;
// @public @deprecated
export function getFocusStyle(theme: ITheme, inset?: number, position?: 'relative' | 'absolute', highContrastStyle?: IRawStyle | undefined, borderColor?: string, outlineColor?: string, isFocusedOnly?: boolean, borderRadius?: string | number | undefined): IRawStyle;
// @public
export function getGlobalClassNames<T>(classNames: GlobalClassNames<T>, theme: ITheme, disableGlobalClassNames?: boolean): GlobalClassNames<T>;
// @public
export function getHighContrastNoAdjustStyle(): IRawStyle;
// @public
export function getIcon(name?: string): IIconRecord | undefined;
// @public
export function getIconClassName(name: string): string;
// @public
Upgrade to ts 4.0 (#17932) * Upgrade to ts 4.0 - Update change files for consistency - Fix some pr comments - fix merge - Change files - Add change files - update api - fix api-extractor warnings * Update packages/react-portal/src/components/Portal/renderPortal.tsx Co-authored-by: Oleksandr Fediashov <alexander.mcgarret@gmail.com> * Update packages/react-conformance/package.json Co-authored-by: Elizabeth Craig <ecraig12345@gmail.com> * Update packages/react-badge/src/components/Badge/useBadgeStyles.ts Co-authored-by: Elizabeth Craig <ecraig12345@gmail.com> * Update packages/fluentui/react-northstar/src/components/Datepicker/DatepickerCalendarHeaderAction.tsx Co-authored-by: Oleksandr Fediashov <alexander.mcgarret@gmail.com> * Update packages/react-badge/src/components/CounterBadge/useCounterBadgeStyles.ts Co-authored-by: Oleksandr Fediashov <alexander.mcgarret@gmail.com> * Update prop types for ComponentBestPractices * Temporarily add anys to fix merge conflict. * fix DatepickerCalendarHeader.tsx to avoid "any" * fluentui/styles/src/types.ts: fix types * packages/fluentui/local-sandbox/tsconfig.json: rollback to esnext * react-menu/src/components/MenuGroupHeader/useMenuGroupHeader.ts: simplify signature * react-menu/src/components/MenuGroup/useMenuGroup.ts: simplify signature * @fluentui/babel-make-styles: fix versions after merge * @fluentui/make-styles: update API file * @fluentui/react-menu: use function to simplify definitions * @fluentui/react-menu: update API * react-badge/src/components/PresenceBadge/usePresenceBadgeStyles.ts: simplify signature * useTabsterAttributes.ts: fix signature * useMenuList.ts: remove cast to any * Change files * useTriggerElement.tsx: fix types * getBoundary.ts: remove useless typecast * useAccordionItem.ts: simplify typings * useTriggerElement-test.tsx: fix types in test * Update packages/react/src/components/List/List.tsx Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com> * Revert change, update api docs * Revert changes to web-components/package.json * PR feedback * Reconcile tslib versions * Formatting * Update change/@fluentui-web-components-057bb4b4-9195-499c-a1c4-4fdb458f1302.json Co-authored-by: Chris Holt <chhol@microsoft.com> * Re-resolve merge conflicts * Update packages/react/src/components/List/List.tsx Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com> * Update packages/eslint-plugin/package.json Co-authored-by: Elizabeth Craig <ecraig12345@gmail.com> * Update packages/react/src/components/List/List.tsx Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com> * Update packages/react/src/components/MarqueeSelection/MarqueeSelection.base.tsx Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com> * Update packages/react/src/components/MarqueeSelection/MarqueeSelection.base.tsx Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com> * PR feedback * update API * Formatting * fix regression on render callback * Update packages/fluentui/local-sandbox/webpack.config.js Co-authored-by: Elizabeth Craig <ecraig12345@gmail.com> * Update nohoist Co-authored-by: Jon S <joschect@microsoft.com> Co-authored-by: Oleksandr Fediashov <alexander.mcgarret@gmail.com> Co-authored-by: Elizabeth Craig <ecraig12345@gmail.com> Co-authored-by: Oleksandr Fediashov <olfedias@microsoft.com> Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com> Co-authored-by: Chris Holt <chhol@microsoft.com>
2021-04-30 05:25:01 +03:00
export const getInputFocusStyle: (borderColor: string, borderRadius: string | number, borderType?: 'border' | 'borderBottom', borderPosition?: number) => IRawStyle;
// @public
export function getPlaceholderStyles(styles: IStyle): IStyle;
// @public (undocumented)
export function getScreenSelector(min: number | undefined, max: number | undefined): string;
// @public
export function getTheme(depComments?: boolean): ITheme;
// Warning: (ae-internal-missing-underscore) The name "getThemedContext" should be prefixed with an underscore because the declaration is marked as @internal
//
// @internal
export function getThemedContext(context: ICustomizerContext, scheme?: ISchemeNames, theme?: ITheme): ICustomizerContext;
// @public (undocumented)
export type GlobalClassNames<IStyles> = Record<keyof IStyles, string>;
// @public (undocumented)
export const hiddenContentStyle: IRawStyle;
// @public (undocumented)
export const HighContrastSelector = "@media screen and (-ms-high-contrast: active), screen and (forced-colors: active)";
// @public (undocumented)
export const HighContrastSelectorBlack = "@media screen and (-ms-high-contrast: white-on-black), screen and (forced-colors: active) and (prefers-color-scheme: dark)";
// @public (undocumented)
export const HighContrastSelectorWhite = "@media screen and (-ms-high-contrast: black-on-white), screen and (forced-colors: active) and (prefers-color-scheme: light)";
export { IAnimationStyles }
export { IAnimationVariables }
export { IconFontSizes }
export { ICSPSettings }
export { IEffects }
export { IFontFace }
export { IFontStyles }
export { IFontWeight }
// @public (undocumented)
export interface IGetFocusStylesOptions {
borderColor?: string;
borderRadius?: string | number | undefined;
highContrastStyle?: IRawStyle;
inset?: number;
isFocusedOnly?: boolean;
outlineColor?: string;
pointerEvents?: IRawStyle['pointerEvents'];
position?: 'relative' | 'absolute';
width?: number;
}
// @public (undocumented)
export interface IIconOptions {
disableWarnings: boolean;
// @deprecated (undocumented)
warnOnMissingIcons?: boolean;
}
// @public (undocumented)
export interface IIconRecord {
// (undocumented)
code: string | undefined;
// (undocumented)
subset: IIconSubsetRecord;
}
// @public (undocumented)
export interface IIconSubset {
// (undocumented)
fontFace?: IFontFace;
// (undocumented)
icons: {
[key: string]: string | JSX.Element;
};
mergeImageProps?: boolean;
// (undocumented)
style?: IRawStyle;
}
// @public (undocumented)
export interface IIconSubsetRecord extends IIconSubset {
// (undocumented)
className?: string;
// (undocumented)
isRegistered?: boolean;
}
export { InjectionMode }
export { IPalette }
export { IPartialTheme }
export { IProcessedStyleSet }
export { IRawStyle }
export { IScheme }
export { ISchemeNames }
export { ISemanticColors }
export { ISemanticTextColors }
export { ISpacing }
export { IStyle }
export { IStyleSet }
export { IStyleSetBase }
export { IStyleSheetConfig }
export { ITheme }
export { keyframes }
// @public
export function loadTheme(theme: IPartialTheme, depComments?: boolean): ITheme;
export { mergeStyles }
export { mergeStyleSets }
// @public (undocumented)
export const normalize: IRawStyle;
// @public (undocumented)
export const noWrap: IRawStyle;
// @public (undocumented)
export const PulsingBeaconAnimationStyles: {
continuousPulseAnimationDouble: typeof _continuousPulseAnimationDouble;
continuousPulseAnimationSingle: typeof _continuousPulseAnimationSingle;
createDefaultAnimation: typeof _createDefaultAnimation;
};
export { registerDefaultFontFaces }
// @public
export function registerIconAlias(iconName: string, mappedToName: string): void;
// @public
export function registerIcons(iconSubset: IIconSubset, options?: Partial<IIconOptions>): void;
// @public
export function registerOnThemeChangeCallback(callback: (theme: ITheme) => void): void;
// @public
export function removeOnThemeChangeCallback(callback: (theme: ITheme) => void): void;
// @public (undocumented)
export const ScreenWidthMaxLarge: number;
// @public (undocumented)
export const ScreenWidthMaxMedium: number;
// @public (undocumented)
export const ScreenWidthMaxSmall: number;
// @public (undocumented)
export const ScreenWidthMaxXLarge: number;
// @public (undocumented)
export const ScreenWidthMaxXXLarge: number;
// @public (undocumented)
export const ScreenWidthMinLarge = 640;
// @public (undocumented)
export const ScreenWidthMinMedium = 480;
// @public (undocumented)
export const ScreenWidthMinSmall = 320;
// @public (undocumented)
export const ScreenWidthMinUhfMobile = 768;
// @public (undocumented)
export const ScreenWidthMinXLarge = 1024;
// @public (undocumented)
export const ScreenWidthMinXXLarge = 1366;
// @public (undocumented)
export const ScreenWidthMinXXXLarge = 1920;
// @public
export function setIconOptions(options: Partial<IIconOptions>): void;
export { ShadowConfig }
export { Stylesheet }
// @public (undocumented)
export const ThemeSettingName = "theme";
// @public
export function unregisterIcons(iconNames: string[]): void;
// @public (undocumented)
export namespace ZIndexes {
const // (undocumented)
Nav: number;
const // @deprecated (undocumented)
ScrollablePane: number;
const // (undocumented)
FocusStyle: number;
const // (undocumented)
Coachmark: number;
const // (undocumented)
Layer: number;
const // (undocumented)
KeytipLayer: number;
}
// Warnings were encountered during analysis:
//
// lib/styles/PulsingBeaconAnimationStyles.d.ts:6:5 - (ae-forgotten-export) The symbol "_continuousPulseAnimationDouble" needs to be exported by the entry point index.d.ts
// lib/styles/PulsingBeaconAnimationStyles.d.ts:7:5 - (ae-forgotten-export) The symbol "_continuousPulseAnimationSingle" needs to be exported by the entry point index.d.ts
// lib/styles/PulsingBeaconAnimationStyles.d.ts:8:5 - (ae-forgotten-export) The symbol "_createDefaultAnimation" needs to be exported by the entry point index.d.ts
// (No @packageDocumentation comment for this package)
```