Родитель
cc7810f1ea
Коммит
5aee9ae9aa
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"type": "patch",
|
||||
"comment": "Export shimmer consts",
|
||||
"packageName": "@fluentui-react-native/experimental-shimmer",
|
||||
"email": "ruaraki@microsoft.com",
|
||||
"dependentChangeType": "patch"
|
||||
}
|
|
@ -1,13 +1,14 @@
|
|||
import type { Theme } from '@fluentui-react-native/framework';
|
||||
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
||||
|
||||
import { shimmerDefaultAngle, shimmerDefaultDelay, shimmerDefaultDuration } from './consts';
|
||||
import type { ShimmerTokens } from './Shimmer.types';
|
||||
|
||||
export const defaultShimmerTokens: TokenSettings<ShimmerTokens, Theme> = (theme: Theme) =>
|
||||
({
|
||||
angle: 45,
|
||||
delay: 0,
|
||||
duration: 1000,
|
||||
angle: shimmerDefaultAngle,
|
||||
delay: shimmerDefaultDelay,
|
||||
duration: shimmerDefaultDuration,
|
||||
shimmerColor: theme.colors.neutralStencil1,
|
||||
shimmerColorOpacity: 1,
|
||||
shimmerWaveColor: theme.colors.neutralStencil2,
|
||||
|
|
|
@ -1,13 +1,14 @@
|
|||
import type { Theme } from '@fluentui-react-native/framework';
|
||||
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
||||
|
||||
import { shimmerDefaultAngle, shimmerDefaultDelay, shimmerDefaultDuration } from './consts';
|
||||
import type { ShimmerTokens } from './Shimmer.types';
|
||||
|
||||
export const defaultShimmerTokens: TokenSettings<ShimmerTokens, Theme> = (theme: Theme) =>
|
||||
({
|
||||
angle: 0,
|
||||
delay: 0,
|
||||
duration: 1000,
|
||||
angle: shimmerDefaultAngle,
|
||||
delay: shimmerDefaultDelay,
|
||||
duration: shimmerDefaultDuration,
|
||||
shimmerColor: theme.colors.neutralStencil1,
|
||||
shimmerColorOpacity: 1,
|
||||
shimmerWaveColor: theme.colors.neutralStencil2,
|
||||
|
|
|
@ -2,14 +2,15 @@ import type { Theme } from '@fluentui-react-native/framework';
|
|||
import { getCurrentAppearance } from '@fluentui-react-native/theming-utils';
|
||||
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
||||
|
||||
import { shimmerDefaultAngle, shimmerDefaultDelay, shimmerDefaultDuration } from './consts';
|
||||
import type { ShimmerTokens } from './Shimmer.types';
|
||||
|
||||
export const defaultShimmerTokens: TokenSettings<ShimmerTokens, Theme> = (theme: Theme) =>
|
||||
({
|
||||
angle: 0,
|
||||
angle: shimmerDefaultAngle,
|
||||
backgroundColor: theme.colors.transparentBackground,
|
||||
delay: 0,
|
||||
duration: 7000,
|
||||
delay: shimmerDefaultDelay,
|
||||
duration: shimmerDefaultDuration,
|
||||
shimmerColor: getCurrentAppearance(theme.host.appearance, 'light') === 'light' ? '#E1E1E1' : '#404040',
|
||||
shimmerColorOpacity: 1,
|
||||
shimmerWaveColor: getCurrentAppearance(theme.host.appearance, 'light') === 'light' ? 'white' : 'black',
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
import type { Theme } from '@fluentui-react-native/framework';
|
||||
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
||||
|
||||
import { shimmerDefaultAngle, shimmerDefaultDelay, shimmerDefaultDuration } from './consts';
|
||||
import type { ShimmerTokens } from './Shimmer.types';
|
||||
|
||||
export const defaultShimmerTokens: TokenSettings<ShimmerTokens, Theme> = (theme: Theme) =>
|
||||
({
|
||||
angle: 0,
|
||||
angle: shimmerDefaultAngle,
|
||||
backgroundColor: theme.colors.background,
|
||||
delay: 500,
|
||||
duration: 2000,
|
||||
delay: shimmerDefaultDelay,
|
||||
duration: shimmerDefaultDuration,
|
||||
shimmerColor: theme.colors.bodyFrameDivider,
|
||||
shimmerColorOpacity: 1,
|
||||
shimmerWaveColor: '#E1E1E1',
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
export const shimmerDefaultAngle = 45;
|
||||
export const shimmerDefaultDelay = 0;
|
||||
export const shimmerDefaultDuration = 1000;
|
|
@ -0,0 +1,3 @@
|
|||
export const shimmerDefaultAngle = 0;
|
||||
export const shimmerDefaultDelay = 0;
|
||||
export const shimmerDefaultDuration = 1000;
|
|
@ -0,0 +1,3 @@
|
|||
export const shimmerDefaultAngle = 0;
|
||||
export const shimmerDefaultDelay = 0;
|
||||
export const shimmerDefaultDuration = 7000;
|
|
@ -0,0 +1,3 @@
|
|||
export const shimmerDefaultAngle = 0;
|
||||
export const shimmerDefaultDelay = 500;
|
||||
export const shimmerDefaultDuration = 2000;
|
|
@ -9,3 +9,4 @@ export type {
|
|||
ShimmerTokens,
|
||||
ShimmerType,
|
||||
} from './Shimmer.types';
|
||||
export { shimmerDefaultAngle, shimmerDefaultDelay, shimmerDefaultDuration } from './consts';
|
||||
|
|
Загрузка…
Ссылка в новой задаче