@fluentui/react-badge 0.0.0-nightly-20220518-0420.1 → 0.0.0-nightly-20220519-0420.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.json +15 -9
- package/CHANGELOG.md +8 -7
- package/{lib → dist}/tsdoc-metadata.json +0 -0
- package/package.json +6 -6
- package/lib/Badge.d.ts +0 -1
- package/lib/CounterBadge.d.ts +0 -1
- package/lib/PresenceBadge.d.ts +0 -1
- package/lib/components/Badge/Badge.d.ts +0 -6
- package/lib/components/Badge/Badge.types.d.ts +0 -33
- package/lib/components/Badge/index.d.ts +0 -5
- package/lib/components/Badge/renderBadge.d.ts +0 -2
- package/lib/components/Badge/useBadge.d.ts +0 -6
- package/lib/components/Badge/useBadgeStyles.d.ts +0 -11
- package/lib/components/CounterBadge/CounterBadge.d.ts +0 -6
- package/lib/components/CounterBadge/CounterBadge.types.d.ts +0 -42
- package/lib/components/CounterBadge/index.d.ts +0 -4
- package/lib/components/CounterBadge/useCounterBadge.d.ts +0 -6
- package/lib/components/CounterBadge/useCounterBadgeStyles.d.ts +0 -12
- package/lib/components/PresenceBadge/PresenceBadge.d.ts +0 -6
- package/lib/components/PresenceBadge/PresenceBadge.types.d.ts +0 -17
- package/lib/components/PresenceBadge/index.d.ts +0 -4
- package/lib/components/PresenceBadge/presenceIcons.d.ts +0 -11
- package/lib/components/PresenceBadge/usePresenceBadge.d.ts +0 -6
- package/lib/components/PresenceBadge/usePresenceBadgeStyles.d.ts +0 -12
- package/lib/index.d.ts +0 -6
- package/lib-commonjs/Badge.d.ts +0 -1
- package/lib-commonjs/CounterBadge.d.ts +0 -1
- package/lib-commonjs/PresenceBadge.d.ts +0 -1
- package/lib-commonjs/components/Badge/Badge.d.ts +0 -6
- package/lib-commonjs/components/Badge/Badge.types.d.ts +0 -33
- package/lib-commonjs/components/Badge/index.d.ts +0 -5
- package/lib-commonjs/components/Badge/renderBadge.d.ts +0 -2
- package/lib-commonjs/components/Badge/useBadge.d.ts +0 -6
- package/lib-commonjs/components/Badge/useBadgeStyles.d.ts +0 -11
- package/lib-commonjs/components/CounterBadge/CounterBadge.d.ts +0 -6
- package/lib-commonjs/components/CounterBadge/CounterBadge.types.d.ts +0 -42
- package/lib-commonjs/components/CounterBadge/index.d.ts +0 -4
- package/lib-commonjs/components/CounterBadge/useCounterBadge.d.ts +0 -6
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.d.ts +0 -12
- package/lib-commonjs/components/PresenceBadge/PresenceBadge.d.ts +0 -6
- package/lib-commonjs/components/PresenceBadge/PresenceBadge.types.d.ts +0 -17
- package/lib-commonjs/components/PresenceBadge/index.d.ts +0 -4
- package/lib-commonjs/components/PresenceBadge/presenceIcons.d.ts +0 -11
- package/lib-commonjs/components/PresenceBadge/usePresenceBadge.d.ts +0 -6
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.d.ts +0 -12
- package/lib-commonjs/index.d.ts +0 -6
package/CHANGELOG.json
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
"name": "@fluentui/react-badge",
|
|
3
3
|
"entries": [
|
|
4
4
|
{
|
|
5
|
-
"date": "
|
|
6
|
-
"tag": "@fluentui/react-badge_v0.0.0-nightly-
|
|
7
|
-
"version": "0.0.0-nightly-
|
|
5
|
+
"date": "Thu, 19 May 2022 04:30:58 GMT",
|
|
6
|
+
"tag": "@fluentui/react-badge_v0.0.0-nightly-20220519-0420.1",
|
|
7
|
+
"version": "0.0.0-nightly-20220519-0420.1",
|
|
8
8
|
"comments": {
|
|
9
9
|
"none": [
|
|
10
10
|
{
|
|
@@ -15,6 +15,12 @@
|
|
|
15
15
|
}
|
|
16
16
|
],
|
|
17
17
|
"prerelease": [
|
|
18
|
+
{
|
|
19
|
+
"author": "tristan.watanabe@gmail.com",
|
|
20
|
+
"package": "@fluentui/react-badge",
|
|
21
|
+
"commit": "2e5bf6decb7ac952a490a1cb626f0c6d0a064e4b",
|
|
22
|
+
"comment": "react-badge: ship rolluped only dts."
|
|
23
|
+
},
|
|
18
24
|
{
|
|
19
25
|
"author": "sarah.higley@microsoft.com",
|
|
20
26
|
"package": "@fluentui/react-badge",
|
|
@@ -36,20 +42,20 @@
|
|
|
36
42
|
{
|
|
37
43
|
"author": "beachball",
|
|
38
44
|
"package": "@fluentui/react-badge",
|
|
39
|
-
"comment": "Bump @fluentui/react-theme to v0.0.0-nightly-
|
|
40
|
-
"commit": "
|
|
45
|
+
"comment": "Bump @fluentui/react-theme to v0.0.0-nightly-20220519-0420.1",
|
|
46
|
+
"commit": "54a7d23bd4e12f3341618cd1bcac4c4367ed6168"
|
|
41
47
|
},
|
|
42
48
|
{
|
|
43
49
|
"author": "beachball",
|
|
44
50
|
"package": "@fluentui/react-badge",
|
|
45
|
-
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightly-
|
|
46
|
-
"commit": "
|
|
51
|
+
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightly-20220519-0420.1",
|
|
52
|
+
"commit": "54a7d23bd4e12f3341618cd1bcac4c4367ed6168"
|
|
47
53
|
},
|
|
48
54
|
{
|
|
49
55
|
"author": "beachball",
|
|
50
56
|
"package": "@fluentui/react-badge",
|
|
51
|
-
"comment": "Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-
|
|
52
|
-
"commit": "
|
|
57
|
+
"comment": "Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-20220519-0420.1",
|
|
58
|
+
"commit": "54a7d23bd4e12f3341618cd1bcac4c4367ed6168"
|
|
53
59
|
}
|
|
54
60
|
]
|
|
55
61
|
}
|
package/CHANGELOG.md
CHANGED
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
# Change Log - @fluentui/react-badge
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Thu, 19 May 2022 04:30:58 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
-
## [0.0.0-nightly-
|
|
7
|
+
## [0.0.0-nightly-20220519-0420.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-badge_v0.0.0-nightly-20220519-0420.1)
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-badge_v9.0.0-rc.8..@fluentui/react-badge_v0.0.0-nightly-
|
|
9
|
+
Thu, 19 May 2022 04:30:58 GMT
|
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-badge_v9.0.0-rc.8..@fluentui/react-badge_v0.0.0-nightly-20220519-0420.1)
|
|
11
11
|
|
|
12
12
|
### Changes
|
|
13
13
|
|
|
14
|
+
- react-badge: ship rolluped only dts. ([PR #23053](https://github.com/microsoft/fluentui/pull/23053) by tristan.watanabe@gmail.com)
|
|
14
15
|
- remove commons types from badges ([PR #22868](https://github.com/microsoft/fluentui/pull/22868) by sarah.higley@microsoft.com)
|
|
15
16
|
- pass in icon props to presence badge icon slot, and use default strings ([PR #22901](https://github.com/microsoft/fluentui/pull/22901) by mgodbolt@microsoft.com)
|
|
16
17
|
- chore: Update Griffel to latest version ([PR #22894](https://github.com/microsoft/fluentui/pull/22894) by olfedias@microsoft.com)
|
|
17
|
-
- Bump @fluentui/react-theme to v0.0.0-nightly-
|
|
18
|
-
- Bump @fluentui/react-utilities to v0.0.0-nightly-
|
|
19
|
-
- Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-
|
|
18
|
+
- Bump @fluentui/react-theme to v0.0.0-nightly-20220519-0420.1 ([commit](https://github.com/microsoft/fluentui/commit/54a7d23bd4e12f3341618cd1bcac4c4367ed6168) by beachball)
|
|
19
|
+
- Bump @fluentui/react-utilities to v0.0.0-nightly-20220519-0420.1 ([commit](https://github.com/microsoft/fluentui/commit/54a7d23bd4e12f3341618cd1bcac4c4367ed6168) by beachball)
|
|
20
|
+
- Bump @fluentui/react-conformance-griffel to v0.0.0-nightly-20220519-0420.1 ([commit](https://github.com/microsoft/fluentui/commit/54a7d23bd4e12f3341618cd1bcac4c4367ed6168) by beachball)
|
|
20
21
|
|
|
21
22
|
## [9.0.0-rc.8](https://github.com/microsoft/fluentui/tree/@fluentui/react-badge_v9.0.0-rc.8)
|
|
22
23
|
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui/react-badge",
|
|
3
|
-
"version": "0.0.0-nightly-
|
|
3
|
+
"version": "0.0.0-nightly-20220519-0420.1",
|
|
4
4
|
"description": "React components for building web experiences",
|
|
5
5
|
"main": "lib-commonjs/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
7
|
-
"typings": "
|
|
7
|
+
"typings": "dist/index.d.ts",
|
|
8
8
|
"sideEffects": false,
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
@@ -21,21 +21,21 @@
|
|
|
21
21
|
"start": "yarn storybook",
|
|
22
22
|
"test": "jest --passWithNoTests",
|
|
23
23
|
"docs": "api-extractor run --config=config/api-extractor.local.json --local",
|
|
24
|
-
"build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../../scripts/typescript/normalize-import --output ./dist/packages/react-components/react-badge/src && yarn docs",
|
|
24
|
+
"build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../../scripts/typescript/normalize-import --output ./dist/types/packages/react-components/react-badge/src && yarn docs",
|
|
25
25
|
"storybook": "node ../../../scripts/storybook/runner",
|
|
26
26
|
"type-check": "tsc -b tsconfig.json"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"@fluentui/eslint-plugin": "*",
|
|
30
30
|
"@fluentui/react-conformance": "*",
|
|
31
|
-
"@fluentui/react-conformance-griffel": "0.0.0-nightly-
|
|
31
|
+
"@fluentui/react-conformance-griffel": "0.0.0-nightly-20220519-0420.1",
|
|
32
32
|
"@fluentui/scripts": "^1.0.0"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@fluentui/react-icons": "^2.0.166-rc.3",
|
|
36
36
|
"@griffel/react": "1.0.4",
|
|
37
|
-
"@fluentui/react-theme": "0.0.0-nightly-
|
|
38
|
-
"@fluentui/react-utilities": "0.0.0-nightly-
|
|
37
|
+
"@fluentui/react-theme": "0.0.0-nightly-20220519-0420.1",
|
|
38
|
+
"@fluentui/react-utilities": "0.0.0-nightly-20220519-0420.1",
|
|
39
39
|
"tslib": "^2.1.0"
|
|
40
40
|
},
|
|
41
41
|
"peerDependencies": {
|
package/lib/Badge.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './components/Badge/index';
|
package/lib/CounterBadge.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './components/CounterBadge/index';
|
package/lib/PresenceBadge.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './components/PresenceBadge/index';
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';
|
|
2
|
-
export declare type BadgeSlots = {
|
|
3
|
-
root: Slot<'div'>;
|
|
4
|
-
icon?: Slot<'span'>;
|
|
5
|
-
};
|
|
6
|
-
export declare type BadgeProps = Omit<ComponentProps<BadgeSlots>, 'color'> & {
|
|
7
|
-
/**
|
|
8
|
-
* A Badge can be filled, outline, ghost, inverted
|
|
9
|
-
* @defaultvalue filled
|
|
10
|
-
*/
|
|
11
|
-
appearance?: 'filled' | 'ghost' | 'outline' | 'tint';
|
|
12
|
-
/**
|
|
13
|
-
* A Badge can be one of preset colors
|
|
14
|
-
* @defaultvalue brand
|
|
15
|
-
*/
|
|
16
|
-
color?: 'brand' | 'danger' | 'important' | 'informative' | 'severe' | 'subtle' | 'success' | 'warning';
|
|
17
|
-
/**
|
|
18
|
-
* A Badge can position the icon before or after the content.
|
|
19
|
-
* @defaultvalue before
|
|
20
|
-
*/
|
|
21
|
-
iconPosition?: 'before' | 'after';
|
|
22
|
-
/**
|
|
23
|
-
* A Badge can be square, circular or rounded.
|
|
24
|
-
* @defaultvalue circular
|
|
25
|
-
*/
|
|
26
|
-
shape?: 'circular' | 'rounded' | 'square';
|
|
27
|
-
/**
|
|
28
|
-
* A Badge can be on of several preset sizes.
|
|
29
|
-
* @defaultvalue medium
|
|
30
|
-
*/
|
|
31
|
-
size?: 'tiny' | 'extra-small' | 'small' | 'medium' | 'large' | 'extra-large';
|
|
32
|
-
};
|
|
33
|
-
export declare type BadgeState = ComponentState<BadgeSlots> & Required<Pick<BadgeProps, 'appearance' | 'color' | 'iconPosition' | 'shape' | 'size'>>;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { BadgeProps, BadgeState } from './Badge.types';
|
|
3
|
-
/**
|
|
4
|
-
* Returns the props and state required to render the component
|
|
5
|
-
*/
|
|
6
|
-
export declare const useBadge_unstable: (props: BadgeProps, ref: React.Ref<HTMLElement>) => BadgeState;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { BadgeSlots, BadgeState } from './Badge.types';
|
|
2
|
-
import type { SlotClassNames } from '@fluentui/react-utilities';
|
|
3
|
-
/**
|
|
4
|
-
* @deprecated Use `badgeClassNames.root` instead.
|
|
5
|
-
*/
|
|
6
|
-
export declare const badgeClassName = "fui-Badge";
|
|
7
|
-
export declare const badgeClassNames: SlotClassNames<BadgeSlots>;
|
|
8
|
-
/**
|
|
9
|
-
* Applies style classnames to slots
|
|
10
|
-
*/
|
|
11
|
-
export declare const useBadgeStyles_unstable: (state: BadgeState) => BadgeState;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { CounterBadgeProps } from './CounterBadge.types';
|
|
2
|
-
import type { ForwardRefComponent } from '@fluentui/react-utilities';
|
|
3
|
-
/**
|
|
4
|
-
* Define a styled CounterBadge, using the `useCounterBadge_unstable` hook.
|
|
5
|
-
*/
|
|
6
|
-
export declare const CounterBadge: ForwardRefComponent<CounterBadgeProps>;
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import type { BadgeProps, BadgeState } from '../Badge/index';
|
|
2
|
-
export declare type CounterBadgeProps = Omit<BadgeProps, 'appearance' | 'color' | 'shape'> & {
|
|
3
|
-
/**
|
|
4
|
-
* A Badge can have different appearances that emphasize certain parts of it:
|
|
5
|
-
* - filled: The default appearance if one is not specified.
|
|
6
|
-
* The badge background is filled with color with a contrasting foreground text to match.
|
|
7
|
-
* - ghost: The badge background is transparent, with the foreground text taking color to emphasize it.
|
|
8
|
-
* @default filled
|
|
9
|
-
*/
|
|
10
|
-
appearance?: 'filled' | 'ghost';
|
|
11
|
-
/**
|
|
12
|
-
* Semantic colors for a counter badge
|
|
13
|
-
* @default brand
|
|
14
|
-
*/
|
|
15
|
-
color?: Extract<BadgeProps['color'], 'brand' | 'danger' | 'important' | 'informative'>;
|
|
16
|
-
/**
|
|
17
|
-
* Value displayed by the Badge
|
|
18
|
-
* @default 0
|
|
19
|
-
*/
|
|
20
|
-
count?: number;
|
|
21
|
-
/**
|
|
22
|
-
* If a dot should be displayed without the count
|
|
23
|
-
* @default false
|
|
24
|
-
*/
|
|
25
|
-
dot?: boolean;
|
|
26
|
-
/**
|
|
27
|
-
* Max number to be displayed
|
|
28
|
-
* @default 99
|
|
29
|
-
*/
|
|
30
|
-
overflowCount?: number;
|
|
31
|
-
/**
|
|
32
|
-
* A Badge can be circular or rounded
|
|
33
|
-
* @default circular
|
|
34
|
-
*/
|
|
35
|
-
shape?: 'circular' | 'rounded';
|
|
36
|
-
/**
|
|
37
|
-
* If the badge should be shown when count is 0
|
|
38
|
-
* @default false
|
|
39
|
-
*/
|
|
40
|
-
showZero?: boolean;
|
|
41
|
-
};
|
|
42
|
-
export declare type CounterBadgeState = Omit<BadgeState, 'appearance' | 'color' | 'shape'> & Required<Pick<CounterBadgeProps, 'appearance' | 'color' | 'count' | 'dot' | 'shape' | 'showZero'>>;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { CounterBadgeProps, CounterBadgeState } from './CounterBadge.types';
|
|
3
|
-
/**
|
|
4
|
-
* Returns the props and state required to render the component
|
|
5
|
-
*/
|
|
6
|
-
export declare const useCounterBadge_unstable: (props: CounterBadgeProps, ref: React.Ref<HTMLElement>) => CounterBadgeState;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { SlotClassNames } from '@fluentui/react-utilities';
|
|
2
|
-
import type { BadgeSlots } from '../Badge/Badge.types';
|
|
3
|
-
import type { CounterBadgeState } from './CounterBadge.types';
|
|
4
|
-
/**
|
|
5
|
-
* @deprecated Use `counterBadgeClassNames.root` instead.
|
|
6
|
-
*/
|
|
7
|
-
export declare const counterBadgeClassName = "fui-CounterBadge";
|
|
8
|
-
export declare const counterBadgeClassNames: SlotClassNames<BadgeSlots>;
|
|
9
|
-
/**
|
|
10
|
-
* Applies style classnames to slots
|
|
11
|
-
*/
|
|
12
|
-
export declare const useCounterBadgeStyles_unstable: (state: CounterBadgeState) => CounterBadgeState;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { PresenceBadgeProps } from './PresenceBadge.types';
|
|
2
|
-
import type { ForwardRefComponent } from '@fluentui/react-utilities';
|
|
3
|
-
/**
|
|
4
|
-
* Define a styled Badge, using the `useBadge_unstable` hook.
|
|
5
|
-
*/
|
|
6
|
-
export declare const PresenceBadge: ForwardRefComponent<PresenceBadgeProps>;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { ComponentProps, ComponentState } from '@fluentui/react-utilities';
|
|
2
|
-
import type { BadgeProps, BadgeState, BadgeSlots } from '../Badge/Badge.types';
|
|
3
|
-
export declare type PresenceBadgeStatus = 'busy' | 'outOfOffice' | 'away' | 'available' | 'offline' | 'doNotDisturb' | 'unknown';
|
|
4
|
-
export declare type PresenceBadgeProps = Omit<ComponentProps<Pick<BadgeSlots, 'root' | 'icon'>>, 'color'> & Pick<BadgeProps, 'size'> & {
|
|
5
|
-
/**
|
|
6
|
-
* Represents several status
|
|
7
|
-
* @default available
|
|
8
|
-
*/
|
|
9
|
-
status?: PresenceBadgeStatus;
|
|
10
|
-
/**
|
|
11
|
-
* Modifies the display to indicate that the user is out of office.
|
|
12
|
-
* This can be combined with any status to display an out-of-office version of that status
|
|
13
|
-
* @default false
|
|
14
|
-
*/
|
|
15
|
-
outOfOffice?: boolean;
|
|
16
|
-
};
|
|
17
|
-
export declare type PresenceBadgeState = ComponentState<BadgeSlots> & BadgeState & Required<Pick<PresenceBadgeProps, 'status' | 'outOfOffice'>>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { PresenceBadgeState } from './PresenceBadge.types';
|
|
3
|
-
export declare const presenceAwayFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
4
|
-
export declare const presenceAvailableRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
5
|
-
export declare const presenceAvailableFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
6
|
-
export declare const presenceBusyFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
7
|
-
export declare const presenceDndFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
8
|
-
export declare const presenceDndRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
9
|
-
export declare const presenceOofRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
10
|
-
export declare const presenceOfflineRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
11
|
-
export declare const presenceUnknownRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { PresenceBadgeProps, PresenceBadgeState } from './PresenceBadge.types';
|
|
3
|
-
/**
|
|
4
|
-
* Returns the props and state required to render the component
|
|
5
|
-
*/
|
|
6
|
-
export declare const usePresenceBadge_unstable: (props: PresenceBadgeProps, ref: React.Ref<HTMLElement>) => PresenceBadgeState;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { SlotClassNames } from '@fluentui/react-utilities';
|
|
2
|
-
import type { BadgeSlots } from '../Badge/Badge.types';
|
|
3
|
-
import type { PresenceBadgeState } from './PresenceBadge.types';
|
|
4
|
-
/**
|
|
5
|
-
* @deprecated Use `presenceBadgeClassNames.root` instead.
|
|
6
|
-
*/
|
|
7
|
-
export declare const presenceBadgeClassName = "fui-PresenceBadge";
|
|
8
|
-
export declare const presenceBadgeClassNames: SlotClassNames<BadgeSlots>;
|
|
9
|
-
/**
|
|
10
|
-
* Applies style classnames to slots
|
|
11
|
-
*/
|
|
12
|
-
export declare const usePresenceBadgeStyles_unstable: (state: PresenceBadgeState) => PresenceBadgeState;
|
package/lib/index.d.ts
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export { Badge, badgeClassName, badgeClassNames, renderBadge_unstable, useBadgeStyles_unstable, useBadge_unstable, } from './Badge';
|
|
2
|
-
export type { BadgeProps, BadgeSlots, BadgeState } from './Badge';
|
|
3
|
-
export { PresenceBadge, presenceBadgeClassName, presenceBadgeClassNames, usePresenceBadgeStyles_unstable, usePresenceBadge_unstable, } from './PresenceBadge';
|
|
4
|
-
export type { PresenceBadgeProps, PresenceBadgeState, PresenceBadgeStatus } from './PresenceBadge';
|
|
5
|
-
export { CounterBadge, counterBadgeClassName, counterBadgeClassNames, useCounterBadgeStyles_unstable, useCounterBadge_unstable, } from './CounterBadge';
|
|
6
|
-
export type { CounterBadgeProps, CounterBadgeState } from './CounterBadge';
|
package/lib-commonjs/Badge.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './components/Badge/index';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './components/CounterBadge/index';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './components/PresenceBadge/index';
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';
|
|
2
|
-
export declare type BadgeSlots = {
|
|
3
|
-
root: Slot<'div'>;
|
|
4
|
-
icon?: Slot<'span'>;
|
|
5
|
-
};
|
|
6
|
-
export declare type BadgeProps = Omit<ComponentProps<BadgeSlots>, 'color'> & {
|
|
7
|
-
/**
|
|
8
|
-
* A Badge can be filled, outline, ghost, inverted
|
|
9
|
-
* @defaultvalue filled
|
|
10
|
-
*/
|
|
11
|
-
appearance?: 'filled' | 'ghost' | 'outline' | 'tint';
|
|
12
|
-
/**
|
|
13
|
-
* A Badge can be one of preset colors
|
|
14
|
-
* @defaultvalue brand
|
|
15
|
-
*/
|
|
16
|
-
color?: 'brand' | 'danger' | 'important' | 'informative' | 'severe' | 'subtle' | 'success' | 'warning';
|
|
17
|
-
/**
|
|
18
|
-
* A Badge can position the icon before or after the content.
|
|
19
|
-
* @defaultvalue before
|
|
20
|
-
*/
|
|
21
|
-
iconPosition?: 'before' | 'after';
|
|
22
|
-
/**
|
|
23
|
-
* A Badge can be square, circular or rounded.
|
|
24
|
-
* @defaultvalue circular
|
|
25
|
-
*/
|
|
26
|
-
shape?: 'circular' | 'rounded' | 'square';
|
|
27
|
-
/**
|
|
28
|
-
* A Badge can be on of several preset sizes.
|
|
29
|
-
* @defaultvalue medium
|
|
30
|
-
*/
|
|
31
|
-
size?: 'tiny' | 'extra-small' | 'small' | 'medium' | 'large' | 'extra-large';
|
|
32
|
-
};
|
|
33
|
-
export declare type BadgeState = ComponentState<BadgeSlots> & Required<Pick<BadgeProps, 'appearance' | 'color' | 'iconPosition' | 'shape' | 'size'>>;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { BadgeProps, BadgeState } from './Badge.types';
|
|
3
|
-
/**
|
|
4
|
-
* Returns the props and state required to render the component
|
|
5
|
-
*/
|
|
6
|
-
export declare const useBadge_unstable: (props: BadgeProps, ref: React.Ref<HTMLElement>) => BadgeState;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { BadgeSlots, BadgeState } from './Badge.types';
|
|
2
|
-
import type { SlotClassNames } from '@fluentui/react-utilities';
|
|
3
|
-
/**
|
|
4
|
-
* @deprecated Use `badgeClassNames.root` instead.
|
|
5
|
-
*/
|
|
6
|
-
export declare const badgeClassName = "fui-Badge";
|
|
7
|
-
export declare const badgeClassNames: SlotClassNames<BadgeSlots>;
|
|
8
|
-
/**
|
|
9
|
-
* Applies style classnames to slots
|
|
10
|
-
*/
|
|
11
|
-
export declare const useBadgeStyles_unstable: (state: BadgeState) => BadgeState;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { CounterBadgeProps } from './CounterBadge.types';
|
|
2
|
-
import type { ForwardRefComponent } from '@fluentui/react-utilities';
|
|
3
|
-
/**
|
|
4
|
-
* Define a styled CounterBadge, using the `useCounterBadge_unstable` hook.
|
|
5
|
-
*/
|
|
6
|
-
export declare const CounterBadge: ForwardRefComponent<CounterBadgeProps>;
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import type { BadgeProps, BadgeState } from '../Badge/index';
|
|
2
|
-
export declare type CounterBadgeProps = Omit<BadgeProps, 'appearance' | 'color' | 'shape'> & {
|
|
3
|
-
/**
|
|
4
|
-
* A Badge can have different appearances that emphasize certain parts of it:
|
|
5
|
-
* - filled: The default appearance if one is not specified.
|
|
6
|
-
* The badge background is filled with color with a contrasting foreground text to match.
|
|
7
|
-
* - ghost: The badge background is transparent, with the foreground text taking color to emphasize it.
|
|
8
|
-
* @default filled
|
|
9
|
-
*/
|
|
10
|
-
appearance?: 'filled' | 'ghost';
|
|
11
|
-
/**
|
|
12
|
-
* Semantic colors for a counter badge
|
|
13
|
-
* @default brand
|
|
14
|
-
*/
|
|
15
|
-
color?: Extract<BadgeProps['color'], 'brand' | 'danger' | 'important' | 'informative'>;
|
|
16
|
-
/**
|
|
17
|
-
* Value displayed by the Badge
|
|
18
|
-
* @default 0
|
|
19
|
-
*/
|
|
20
|
-
count?: number;
|
|
21
|
-
/**
|
|
22
|
-
* If a dot should be displayed without the count
|
|
23
|
-
* @default false
|
|
24
|
-
*/
|
|
25
|
-
dot?: boolean;
|
|
26
|
-
/**
|
|
27
|
-
* Max number to be displayed
|
|
28
|
-
* @default 99
|
|
29
|
-
*/
|
|
30
|
-
overflowCount?: number;
|
|
31
|
-
/**
|
|
32
|
-
* A Badge can be circular or rounded
|
|
33
|
-
* @default circular
|
|
34
|
-
*/
|
|
35
|
-
shape?: 'circular' | 'rounded';
|
|
36
|
-
/**
|
|
37
|
-
* If the badge should be shown when count is 0
|
|
38
|
-
* @default false
|
|
39
|
-
*/
|
|
40
|
-
showZero?: boolean;
|
|
41
|
-
};
|
|
42
|
-
export declare type CounterBadgeState = Omit<BadgeState, 'appearance' | 'color' | 'shape'> & Required<Pick<CounterBadgeProps, 'appearance' | 'color' | 'count' | 'dot' | 'shape' | 'showZero'>>;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { CounterBadgeProps, CounterBadgeState } from './CounterBadge.types';
|
|
3
|
-
/**
|
|
4
|
-
* Returns the props and state required to render the component
|
|
5
|
-
*/
|
|
6
|
-
export declare const useCounterBadge_unstable: (props: CounterBadgeProps, ref: React.Ref<HTMLElement>) => CounterBadgeState;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { SlotClassNames } from '@fluentui/react-utilities';
|
|
2
|
-
import type { BadgeSlots } from '../Badge/Badge.types';
|
|
3
|
-
import type { CounterBadgeState } from './CounterBadge.types';
|
|
4
|
-
/**
|
|
5
|
-
* @deprecated Use `counterBadgeClassNames.root` instead.
|
|
6
|
-
*/
|
|
7
|
-
export declare const counterBadgeClassName = "fui-CounterBadge";
|
|
8
|
-
export declare const counterBadgeClassNames: SlotClassNames<BadgeSlots>;
|
|
9
|
-
/**
|
|
10
|
-
* Applies style classnames to slots
|
|
11
|
-
*/
|
|
12
|
-
export declare const useCounterBadgeStyles_unstable: (state: CounterBadgeState) => CounterBadgeState;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { PresenceBadgeProps } from './PresenceBadge.types';
|
|
2
|
-
import type { ForwardRefComponent } from '@fluentui/react-utilities';
|
|
3
|
-
/**
|
|
4
|
-
* Define a styled Badge, using the `useBadge_unstable` hook.
|
|
5
|
-
*/
|
|
6
|
-
export declare const PresenceBadge: ForwardRefComponent<PresenceBadgeProps>;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { ComponentProps, ComponentState } from '@fluentui/react-utilities';
|
|
2
|
-
import type { BadgeProps, BadgeState, BadgeSlots } from '../Badge/Badge.types';
|
|
3
|
-
export declare type PresenceBadgeStatus = 'busy' | 'outOfOffice' | 'away' | 'available' | 'offline' | 'doNotDisturb' | 'unknown';
|
|
4
|
-
export declare type PresenceBadgeProps = Omit<ComponentProps<Pick<BadgeSlots, 'root' | 'icon'>>, 'color'> & Pick<BadgeProps, 'size'> & {
|
|
5
|
-
/**
|
|
6
|
-
* Represents several status
|
|
7
|
-
* @default available
|
|
8
|
-
*/
|
|
9
|
-
status?: PresenceBadgeStatus;
|
|
10
|
-
/**
|
|
11
|
-
* Modifies the display to indicate that the user is out of office.
|
|
12
|
-
* This can be combined with any status to display an out-of-office version of that status
|
|
13
|
-
* @default false
|
|
14
|
-
*/
|
|
15
|
-
outOfOffice?: boolean;
|
|
16
|
-
};
|
|
17
|
-
export declare type PresenceBadgeState = ComponentState<BadgeSlots> & BadgeState & Required<Pick<PresenceBadgeProps, 'status' | 'outOfOffice'>>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { PresenceBadgeState } from './PresenceBadge.types';
|
|
3
|
-
export declare const presenceAwayFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
4
|
-
export declare const presenceAvailableRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
5
|
-
export declare const presenceAvailableFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
6
|
-
export declare const presenceBusyFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
7
|
-
export declare const presenceDndFilled: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
8
|
-
export declare const presenceDndRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
9
|
-
export declare const presenceOofRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
10
|
-
export declare const presenceOfflineRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
11
|
-
export declare const presenceUnknownRegular: Record<PresenceBadgeState['size'], React.FunctionComponent | null>;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { PresenceBadgeProps, PresenceBadgeState } from './PresenceBadge.types';
|
|
3
|
-
/**
|
|
4
|
-
* Returns the props and state required to render the component
|
|
5
|
-
*/
|
|
6
|
-
export declare const usePresenceBadge_unstable: (props: PresenceBadgeProps, ref: React.Ref<HTMLElement>) => PresenceBadgeState;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { SlotClassNames } from '@fluentui/react-utilities';
|
|
2
|
-
import type { BadgeSlots } from '../Badge/Badge.types';
|
|
3
|
-
import type { PresenceBadgeState } from './PresenceBadge.types';
|
|
4
|
-
/**
|
|
5
|
-
* @deprecated Use `presenceBadgeClassNames.root` instead.
|
|
6
|
-
*/
|
|
7
|
-
export declare const presenceBadgeClassName = "fui-PresenceBadge";
|
|
8
|
-
export declare const presenceBadgeClassNames: SlotClassNames<BadgeSlots>;
|
|
9
|
-
/**
|
|
10
|
-
* Applies style classnames to slots
|
|
11
|
-
*/
|
|
12
|
-
export declare const usePresenceBadgeStyles_unstable: (state: PresenceBadgeState) => PresenceBadgeState;
|
package/lib-commonjs/index.d.ts
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export { Badge, badgeClassName, badgeClassNames, renderBadge_unstable, useBadgeStyles_unstable, useBadge_unstable, } from './Badge';
|
|
2
|
-
export type { BadgeProps, BadgeSlots, BadgeState } from './Badge';
|
|
3
|
-
export { PresenceBadge, presenceBadgeClassName, presenceBadgeClassNames, usePresenceBadgeStyles_unstable, usePresenceBadge_unstable, } from './PresenceBadge';
|
|
4
|
-
export type { PresenceBadgeProps, PresenceBadgeState, PresenceBadgeStatus } from './PresenceBadge';
|
|
5
|
-
export { CounterBadge, counterBadgeClassName, counterBadgeClassNames, useCounterBadgeStyles_unstable, useCounterBadge_unstable, } from './CounterBadge';
|
|
6
|
-
export type { CounterBadgeProps, CounterBadgeState } from './CounterBadge';
|