@fluentui/react-badge 0.0.0-nightlybc5ff01fb020211104.1 → 0.0.0-nightlycc44f3625c20211220.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (50) hide show
  1. package/CHANGELOG.json +174 -16
  2. package/CHANGELOG.md +47 -11
  3. package/dist/react-badge.d.ts +12 -7
  4. package/lib/components/Badge/Badge.types.d.ts +1 -1
  5. package/lib/components/Badge/renderBadge.js +4 -1
  6. package/lib/components/Badge/renderBadge.js.map +1 -1
  7. package/lib/components/Badge/useBadgeStyles.js +73 -53
  8. package/lib/components/Badge/useBadgeStyles.js.map +1 -1
  9. package/lib/components/CounterBadge/CounterBadge.types.d.ts +7 -2
  10. package/lib/components/CounterBadge/useCounterBadge.js.map +1 -1
  11. package/lib/components/CounterBadge/useCounterBadgeStyles.js +4 -35
  12. package/lib/components/CounterBadge/useCounterBadgeStyles.js.map +1 -1
  13. package/lib/components/PresenceBadge/PresenceBadge.types.d.ts +6 -5
  14. package/lib/components/PresenceBadge/presenceIcons.d.ts +11 -0
  15. package/lib/components/PresenceBadge/presenceIcons.js +128 -0
  16. package/lib/components/PresenceBadge/presenceIcons.js.map +1 -0
  17. package/lib/components/PresenceBadge/usePresenceBadge.js +29 -15
  18. package/lib/components/PresenceBadge/usePresenceBadge.js.map +1 -1
  19. package/lib/components/PresenceBadge/usePresenceBadgeStyles.js +38 -43
  20. package/lib/components/PresenceBadge/usePresenceBadgeStyles.js.map +1 -1
  21. package/lib-commonjs/components/Badge/Badge.types.d.ts +1 -1
  22. package/lib-commonjs/components/Badge/renderBadge.js +4 -1
  23. package/lib-commonjs/components/Badge/renderBadge.js.map +1 -1
  24. package/lib-commonjs/components/Badge/useBadgeStyles.js +72 -52
  25. package/lib-commonjs/components/Badge/useBadgeStyles.js.map +1 -1
  26. package/lib-commonjs/components/CounterBadge/CounterBadge.types.d.ts +7 -2
  27. package/lib-commonjs/components/CounterBadge/useCounterBadge.js.map +1 -1
  28. package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.js +3 -34
  29. package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.js.map +1 -1
  30. package/lib-commonjs/components/PresenceBadge/PresenceBadge.types.d.ts +6 -5
  31. package/lib-commonjs/components/PresenceBadge/presenceIcons.d.ts +11 -0
  32. package/lib-commonjs/components/PresenceBadge/presenceIcons.js +136 -0
  33. package/lib-commonjs/components/PresenceBadge/presenceIcons.js.map +1 -0
  34. package/lib-commonjs/components/PresenceBadge/usePresenceBadge.js +28 -14
  35. package/lib-commonjs/components/PresenceBadge/usePresenceBadge.js.map +1 -1
  36. package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.js +37 -43
  37. package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.js.map +1 -1
  38. package/package.json +11 -10
  39. package/lib/common/isConformant.d.ts +0 -4
  40. package/lib/common/isConformant.js +0 -13
  41. package/lib/common/isConformant.js.map +0 -1
  42. package/lib/components/PresenceBadge/DefaultPresenceBadgeIcons.d.ts +0 -10
  43. package/lib/components/PresenceBadge/DefaultPresenceBadgeIcons.js +0 -98
  44. package/lib/components/PresenceBadge/DefaultPresenceBadgeIcons.js.map +0 -1
  45. package/lib-commonjs/common/isConformant.d.ts +0 -4
  46. package/lib-commonjs/common/isConformant.js +0 -24
  47. package/lib-commonjs/common/isConformant.js.map +0 -1
  48. package/lib-commonjs/components/PresenceBadge/DefaultPresenceBadgeIcons.d.ts +0 -10
  49. package/lib-commonjs/components/PresenceBadge/DefaultPresenceBadgeIcons.js +0 -113
  50. package/lib-commonjs/components/PresenceBadge/DefaultPresenceBadgeIcons.js.map +0 -1
@@ -12,39 +12,8 @@ const useBadgeStyles_1 = /*#__PURE__*/require("../Badge/useBadgeStyles");
12
12
  exports.counterBadgeClassName = 'fui-CounterBadge';
13
13
 
14
14
  const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
15
- "root": {
16
- "Bf4jedk": "fgfkb25"
17
- },
18
- "warning": {
19
- "De3pzq": "fic4z9l",
20
- "g2u3we": "f1g6aqbb",
21
- "h3c5rm": ["f1xc4egn", "f1y13pv"],
22
- "B9xav0g": "f12f05r9",
23
- "zhjwy3": ["f1y13pv", "f1xc4egn"]
24
- },
25
- "important": {
26
- "De3pzq": "f1y11cvn",
27
- "g2u3we": "f9ag23u",
28
- "h3c5rm": ["fzlvby", "fj2uge6"],
29
- "B9xav0g": "fk41dq4",
30
- "zhjwy3": ["fj2uge6", "fzlvby"]
31
- },
32
- "severe": {
33
- "De3pzq": "ftpr1dl",
34
- "g2u3we": "fx7g4rx",
35
- "h3c5rm": ["f1edxl4n", "f5hlgd2"],
36
- "B9xav0g": "f5ppncr",
37
- "zhjwy3": ["f5hlgd2", "f1edxl4n"]
38
- },
39
- "informative": {
40
- "De3pzq": "f6zwqgc",
41
- "g2u3we": "f1pdtvjr",
42
- "h3c5rm": ["f1ctwv29", "f1m7luuw"],
43
- "B9xav0g": "f1ijpqjr",
44
- "zhjwy3": ["f1m7luuw", "f1ctwv29"],
45
- "sj55zd": "f11d4kpn"
46
- },
47
15
  "dot": {
16
+ "Bf4jedk": "fgfkb25",
48
17
  "a9b677": "f16dn6v3",
49
18
  "Bqenvij": "f3mu39s",
50
19
  "z8tnut": "f1g0x7ka",
@@ -56,7 +25,7 @@ const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
56
25
  "mc9l5x": "fjseox"
57
26
  }
58
27
  }, {
59
- "d": [".fgfkb25{min-width:auto;}", ".fic4z9l{background-color:#c50f1f;}", ".f1g6aqbb{border-top-color:#c50f1f;}", ".f1xc4egn{border-right-color:#c50f1f;}", ".f1y13pv{border-left-color:#c50f1f;}", ".f12f05r9{border-bottom-color:#c50f1f;}", ".f1y11cvn{background-color:#242424;}", ".f9ag23u{border-top-color:#242424;}", ".fzlvby{border-right-color:#242424;}", ".fj2uge6{border-left-color:#242424;}", ".fk41dq4{border-bottom-color:#242424;}", ".ftpr1dl{background-color:#d13438;}", ".fx7g4rx{border-top-color:#d13438;}", ".f1edxl4n{border-right-color:#d13438;}", ".f5hlgd2{border-left-color:#d13438;}", ".f5ppncr{border-bottom-color:#d13438;}", ".f6zwqgc{background-color:#ebebeb;}", ".f1pdtvjr{border-top-color:#ebebeb;}", ".f1ctwv29{border-right-color:#ebebeb;}", ".f1m7luuw{border-left-color:#ebebeb;}", ".f1ijpqjr{border-bottom-color:#ebebeb;}", ".f11d4kpn{color:var(--colorNeutralForeground3);}", ".f16dn6v3{width:6px;}", ".f3mu39s{height:6px;}", ".f1g0x7ka{padding-top:0;}", ".fhxju0i{padding-right:0;}", ".f1cnd47f{padding-left:0;}", ".f1qch9an{padding-bottom:0;}", ".fjseox{display:none;}"]
28
+ "d": [".fgfkb25{min-width:auto;}", ".f16dn6v3{width:6px;}", ".f3mu39s{height:6px;}", ".f1g0x7ka{padding-top:0;}", ".fhxju0i{padding-right:0;}", ".f1cnd47f{padding-left:0;}", ".f1qch9an{padding-bottom:0;}", ".fjseox{display:none;}"]
60
29
  });
61
30
  /**
62
31
  * Applies style classnames to slots
@@ -65,7 +34,7 @@ const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
65
34
 
66
35
  const useCounterBadgeStyles = state => {
67
36
  const styles = useStyles();
68
- state.root.className = react_make_styles_1.mergeClasses(exports.counterBadgeClassName, styles.root, state.color === 'warning' && styles.warning, state.color === 'important' && styles.important, state.color === 'severe' && styles.severe, state.color === 'informative' && styles.informative, state.dot && styles.dot, !state.showZero && state.count === 0 && !state.dot && styles.hide, state.root.className);
37
+ state.root.className = react_make_styles_1.mergeClasses(exports.counterBadgeClassName, state.dot && styles.dot, !state.showZero && state.count === 0 && !state.dot && styles.hide, state.root.className);
69
38
  return useBadgeStyles_1.useBadgeStyles(state);
70
39
  };
71
40
 
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/CounterBadge/useCounterBadgeStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,mBAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;;AACA,MAAA,gBAAA,gBAAA,OAAA,CAAA,yBAAA,C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],"mappings":";;;;;;;AAAA,MAAA,mBAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;;AACA,MAAA,gBAAA,gBAAA,OAAA,CAAA,yBAAA,CAAA;;AAGa,OAAA,CAAA,qBAAA,GAAwB,kBAAxB;;AAEb,MAAM,SAAS,gBAAG,mBAAA,SAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AAYA;;AAEG;;;AACI,MAAM,qBAAqB,GAAI,KAAD,IAAgD;AACnF,QAAM,MAAM,GAAG,SAAS,EAAxB;AACA,EAAA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,mBAAA,CAAA,YAAA,CACrB,OAAA,CAAA,qBADqB,EAErB,KAAK,CAAC,GAAN,IAAa,MAAM,CAAC,GAFC,EAGrB,CAAC,KAAK,CAAC,QAAP,IAAmB,KAAK,CAAC,KAAN,KAAgB,CAAnC,IAAwC,CAAC,KAAK,CAAC,GAA/C,IAAsD,MAAM,CAAC,IAHxC,EAIrB,KAAK,CAAC,IAAN,CAAW,SAJU,CAAvB;AAMA,SAAO,gBAAA,CAAA,cAAA,CAAe,KAAf,CAAP;AACD,CATM;;AAAM,OAAA,CAAA,qBAAA,GAAqB,qBAArB","sourceRoot":""}
@@ -1,6 +1,7 @@
1
- import type { BadgeProps, BadgeState } from '../Badge/index';
1
+ import type { ComponentProps, ComponentState } from '@fluentui/react-utilities';
2
+ import type { BadgeCommons, BadgeSlots } from '../Badge/index';
2
3
  export declare type PresenceBadgeStatus = 'busy' | 'outOfOffice' | 'away' | 'available' | 'offline' | 'doNotDisturb';
3
- export interface PresenceBadgeCommons {
4
+ export declare type PresenceBadgeCommons = {
4
5
  /**
5
6
  * Represents several status
6
7
  * @default available
@@ -12,6 +13,6 @@ export interface PresenceBadgeCommons {
12
13
  * @default false
13
14
  */
14
15
  outOfOffice: boolean;
15
- }
16
- export declare type PresenceBadgeProps = BadgeProps & Partial<PresenceBadgeCommons>;
17
- export declare type PresenceBadgeState = BadgeState & PresenceBadgeCommons;
16
+ } & BadgeCommons;
17
+ export declare type PresenceBadgeProps = ComponentProps<Partial<Pick<BadgeSlots, 'root'>>> & Partial<Pick<PresenceBadgeCommons, 'status' | 'outOfOffice' | 'size'>>;
18
+ export declare type PresenceBadgeState = PresenceBadgeCommons & ComponentState<BadgeSlots>;
@@ -0,0 +1,11 @@
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>;
@@ -0,0 +1,136 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.presenceUnknownRegular = exports.presenceOfflineRegular = exports.presenceOofRegular = exports.presenceDndRegular = exports.presenceDndFilled = exports.presenceBusyFilled = exports.presenceAvailableFilled = exports.presenceAvailableRegular = exports.presenceAwayFilled = void 0;
7
+
8
+ const react_icons_1 = /*#__PURE__*/require("@fluentui/react-icons");
9
+
10
+ exports.presenceAwayFilled = {
11
+ // FIXME not all presence icon sizes are available
12
+ // https://github.com/microsoft/fluentui/issues/20650
13
+ tiny: react_icons_1.PresenceAway10Filled,
14
+ 'extra-small': react_icons_1.PresenceAway10Filled,
15
+ small: react_icons_1.PresenceAway12Filled,
16
+ medium: react_icons_1.PresenceAway16Filled,
17
+ // FIXME not all presence icon sizes are available
18
+ // https://github.com/microsoft/fluentui/issues/20650
19
+ large: react_icons_1.PresenceAway16Filled,
20
+ // FIXME not all presence icon sizes are available
21
+ // https://github.com/microsoft/fluentui/issues/20650
22
+ 'extra-large': react_icons_1.PresenceAway16Filled
23
+ };
24
+ exports.presenceAvailableRegular = {
25
+ // FIXME not all presence icon sizes are available
26
+ // https://github.com/microsoft/fluentui/issues/20650
27
+ tiny: react_icons_1.PresenceAvailable10Regular,
28
+ 'extra-small': react_icons_1.PresenceAvailable10Regular,
29
+ small: react_icons_1.PresenceAvailable12Regular,
30
+ medium: react_icons_1.PresenceAvailable16Regular,
31
+ // FIXME not all presence icon sizes are available
32
+ // https://github.com/microsoft/fluentui/issues/20650
33
+ large: react_icons_1.PresenceAvailable16Regular,
34
+ // FIXME not all presence icon sizes are available
35
+ // https://github.com/microsoft/fluentui/issues/20650
36
+ 'extra-large': react_icons_1.PresenceAvailable16Regular
37
+ };
38
+ exports.presenceAvailableFilled = {
39
+ // FIXME not all presence icon sizes are available
40
+ // https://github.com/microsoft/fluentui/issues/20650
41
+ tiny: react_icons_1.PresenceAvailable10Filled,
42
+ 'extra-small': react_icons_1.PresenceAvailable10Filled,
43
+ small: react_icons_1.PresenceAvailable12Filled,
44
+ medium: react_icons_1.PresenceAvailable16Filled,
45
+ // FIXME not all presence icon sizes are available
46
+ // https://github.com/microsoft/fluentui/issues/20650
47
+ large: react_icons_1.PresenceAvailable16Filled,
48
+ // FIXME not all presence icon sizes are available
49
+ // https://github.com/microsoft/fluentui/issues/20650
50
+ 'extra-large': react_icons_1.PresenceAvailable16Filled
51
+ };
52
+ exports.presenceBusyFilled = {
53
+ // FIXME not all presence icon sizes are available
54
+ // https://github.com/microsoft/fluentui/issues/20650
55
+ tiny: react_icons_1.PresenceBusy10Filled,
56
+ 'extra-small': react_icons_1.PresenceBusy10Filled,
57
+ small: react_icons_1.PresenceBusy12Filled,
58
+ medium: react_icons_1.PresenceBusy16Filled,
59
+ // FIXME not all presence icon sizes are available
60
+ // https://github.com/microsoft/fluentui/issues/20650
61
+ large: react_icons_1.PresenceBusy16Filled,
62
+ // FIXME not all presence icon sizes are available
63
+ // https://github.com/microsoft/fluentui/issues/20650
64
+ 'extra-large': react_icons_1.PresenceBusy16Filled
65
+ };
66
+ exports.presenceDndFilled = {
67
+ // FIXME not all presence icon sizes are available
68
+ // https://github.com/microsoft/fluentui/issues/20650
69
+ tiny: react_icons_1.PresenceDnd10Filled,
70
+ 'extra-small': react_icons_1.PresenceDnd10Filled,
71
+ small: react_icons_1.PresenceDnd12Filled,
72
+ medium: react_icons_1.PresenceDnd16Filled,
73
+ // FIXME not all presence icon sizes are available
74
+ // https://github.com/microsoft/fluentui/issues/20650
75
+ large: react_icons_1.PresenceDnd16Filled,
76
+ // FIXME not all presence icon sizes are available
77
+ // https://github.com/microsoft/fluentui/issues/20650
78
+ 'extra-large': react_icons_1.PresenceDnd16Filled
79
+ };
80
+ exports.presenceDndRegular = {
81
+ // FIXME not all presence icon sizes are available
82
+ // https://github.com/microsoft/fluentui/issues/20650
83
+ tiny: react_icons_1.PresenceDnd10Regular,
84
+ 'extra-small': react_icons_1.PresenceDnd10Regular,
85
+ small: react_icons_1.PresenceDnd12Regular,
86
+ medium: react_icons_1.PresenceDnd16Regular,
87
+ // FIXME not all presence icon sizes are available
88
+ // https://github.com/microsoft/fluentui/issues/20650
89
+ large: react_icons_1.PresenceDnd16Regular,
90
+ // FIXME not all presence icon sizes are available
91
+ // https://github.com/microsoft/fluentui/issues/20650
92
+ 'extra-large': react_icons_1.PresenceDnd16Regular
93
+ };
94
+ exports.presenceOofRegular = {
95
+ // FIXME not all presence icon sizes are available
96
+ // https://github.com/microsoft/fluentui/issues/20650
97
+ tiny: react_icons_1.PresenceOof10Regular,
98
+ 'extra-small': react_icons_1.PresenceOof10Regular,
99
+ small: react_icons_1.PresenceOof12Regular,
100
+ medium: react_icons_1.PresenceOof16Regular,
101
+ // FIXME not all presence icon sizes are available
102
+ // https://github.com/microsoft/fluentui/issues/20650
103
+ large: react_icons_1.PresenceOof16Regular,
104
+ // FIXME not all presence icon sizes are available
105
+ // https://github.com/microsoft/fluentui/issues/20650
106
+ 'extra-large': react_icons_1.PresenceOof16Regular
107
+ };
108
+ exports.presenceOfflineRegular = {
109
+ // FIXME not all presence icon sizes are available
110
+ // https://github.com/microsoft/fluentui/issues/20650
111
+ tiny: react_icons_1.PresenceOffline10Regular,
112
+ 'extra-small': react_icons_1.PresenceOffline10Regular,
113
+ small: react_icons_1.PresenceOffline12Regular,
114
+ medium: react_icons_1.PresenceOffline16Regular,
115
+ // FIXME not all presence icon sizes are available
116
+ // https://github.com/microsoft/fluentui/issues/20650
117
+ large: react_icons_1.PresenceOffline16Regular,
118
+ // FIXME not all presence icon sizes are available
119
+ // https://github.com/microsoft/fluentui/issues/20650
120
+ 'extra-large': react_icons_1.PresenceOffline16Regular
121
+ };
122
+ exports.presenceUnknownRegular = {
123
+ // FIXME not all presence icon sizes are available
124
+ // https://github.com/microsoft/fluentui/issues/20650
125
+ tiny: react_icons_1.PresenceUnknown10Regular,
126
+ 'extra-small': react_icons_1.PresenceUnknown10Regular,
127
+ small: react_icons_1.PresenceUnknown12Regular,
128
+ medium: react_icons_1.PresenceUnknown16Regular,
129
+ // FIXME not all presence icon sizes are available
130
+ // https://github.com/microsoft/fluentui/issues/20650
131
+ large: react_icons_1.PresenceUnknown16Regular,
132
+ // FIXME not all presence icon sizes are available
133
+ // https://github.com/microsoft/fluentui/issues/20650
134
+ 'extra-large': react_icons_1.PresenceUnknown16Regular
135
+ };
136
+ //# sourceMappingURL=presenceIcons.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/components/PresenceBadge/presenceIcons.ts"],"names":[],"mappings":";;;;;;;AACA,MAAA,aAAA,gBAA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wBANgG;AAOxG;AACA;AACA,EAAA,KAAK,EAAE,aAAA,CAAA,wBATiG;AAUxG;AACA;AACA,iBAAe,aAAA,CAAA;AAZyF,CAA7F;AAeA,OAAA,CAAA,sBAAA,GAA6F;AACxG;AACA;AACA,EAAA,IAAI,EAAE,aAAA,CAAA,wBAHkG;AAIxG,iBAAe,aAAA,CAAA,wBAJyF;AAKxG,EAAA,KAAK,EAAE,aAAA,CAAA,wBALiG;AAMxG,EAAA,MAAM,EAAE,aAAA,CAAA,wBANgG;AAOxG;AACA;AACA,EAAA,KAAK,EAAE,aAAA,CAAA,wBATiG;AAUxG;AACA;AACA,iBAAe,aAAA,CAAA;AAZyF,CAA7F","sourceRoot":""}
@@ -9,39 +9,53 @@ const React = /*#__PURE__*/require("react");
9
9
 
10
10
  const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");
11
11
 
12
+ const presenceIcons_1 = /*#__PURE__*/require("./presenceIcons");
13
+
12
14
  const index_1 = /*#__PURE__*/require("../Badge/index");
13
15
 
14
- const DefaultPresenceBadgeIcons_1 = /*#__PURE__*/require("./DefaultPresenceBadgeIcons");
16
+ const iconMap = (status, outOfOffice, size) => {
17
+ switch (status) {
18
+ case 'available':
19
+ return outOfOffice ? presenceIcons_1.presenceAvailableRegular[size] : presenceIcons_1.presenceAvailableFilled[size];
15
20
 
16
- const iconMap = outOfOffice => ({
17
- busy: null,
18
- available: outOfOffice ? React.createElement(DefaultPresenceBadgeIcons_1.SkypeArrowIcon, null) : React.createElement(DefaultPresenceBadgeIcons_1.SkypeCheckIcon, null),
19
- away: outOfOffice ? React.createElement(DefaultPresenceBadgeIcons_1.SkypeArrowIcon, null) : React.createElement(DefaultPresenceBadgeIcons_1.SkypeClockIcon, null),
20
- offline: React.createElement(DefaultPresenceBadgeIcons_1.CancelIcon, null),
21
- outOfOffice: React.createElement(DefaultPresenceBadgeIcons_1.SkypeArrowIcon, null),
22
- doNotDisturb: React.createElement(DefaultPresenceBadgeIcons_1.SkypeMinusIcon, null)
23
- });
21
+ case 'away':
22
+ return outOfOffice ? presenceIcons_1.presenceOfflineRegular[size] : presenceIcons_1.presenceAwayFilled[size];
23
+
24
+ case 'busy':
25
+ return outOfOffice ? presenceIcons_1.presenceUnknownRegular[size] : presenceIcons_1.presenceBusyFilled[size];
26
+
27
+ case 'doNotDisturb':
28
+ return outOfOffice ? presenceIcons_1.presenceDndRegular[size] : presenceIcons_1.presenceDndFilled[size];
29
+
30
+ case 'offline':
31
+ return presenceIcons_1.presenceOfflineRegular[size];
32
+
33
+ case 'outOfOffice':
34
+ return presenceIcons_1.presenceOofRegular[size];
35
+ }
36
+ };
24
37
  /**
25
38
  * Returns the props and state required to render the component
26
39
  */
27
40
 
28
41
 
29
42
  const usePresenceBadge = (props, ref) => {
30
- var _a, _b, _c;
43
+ var _a, _b;
31
44
 
32
45
  const state = { ...index_1.useBadge({
33
- size: 'small',
46
+ size: 'medium',
34
47
  ...props,
35
- icon: react_utilities_1.resolveShorthand(props.icon, {
48
+ icon: react_utilities_1.resolveShorthand(undefined, {
36
49
  required: true
37
50
  })
38
51
  }, ref),
39
52
  status: (_a = props.status) !== null && _a !== void 0 ? _a : 'available',
40
53
  outOfOffice: (_b = props.outOfOffice) !== null && _b !== void 0 ? _b : false
41
54
  };
55
+ const IconElement = iconMap(state.status, state.outOfOffice, state.size);
42
56
 
43
- if (!((_c = state.icon) === null || _c === void 0 ? void 0 : _c.children)) {
44
- state.icon.children = iconMap(state.outOfOffice)[state.status];
57
+ if (IconElement) {
58
+ state.icon.children = React.createElement(IconElement, null);
45
59
  }
46
60
 
47
61
  return state;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/PresenceBadge/usePresenceBadge.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;;AACA,MAAA,OAAA,gBAAA,OAAA,CAAA,gBAAA,CAA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enceBadgeClassName = void 0;
7
7
 
8
8
  const react_make_styles_1 = /*#__PURE__*/require("@fluentui/react-make-styles");
9
9
 
10
- const Badge_1 = /*#__PURE__*/require("../../Badge");
11
-
12
10
  exports.presenceBadgeClassName = 'fui-PresenceBadge';
13
11
 
14
12
  const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
@@ -17,56 +15,34 @@ const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
17
15
  "z189sj": ["fhxju0i", "f1cnd47f"],
18
16
  "Byoj8tv": "f1qch9an",
19
17
  "uwmqm3": ["f1cnd47f", "fhxju0i"],
20
- "B4j52fo": "f18zi460",
21
- "Bekrc4i": ["f1wpluaz", "fsfsuhs"],
22
- "Bn0qgzm": "fmklw6v",
23
- "ibv6hh": ["fsfsuhs", "f1wpluaz"]
24
- },
25
- "thinBorder": {
26
- "B4j52fo": "f192inf7",
27
- "Bekrc4i": ["f5tn483", "f1ojsxk5"],
28
- "Bn0qgzm": "f1vxd6vx",
29
- "ibv6hh": ["f1ojsxk5", "f5tn483"]
18
+ "mc9l5x": "ftuwxu6",
19
+ "B7ck84d": "f1ewtqcl",
20
+ "Bt984gj": "f122n59",
21
+ "Brf1p80": "f4d9j23",
22
+ "Bhmb4qv": "fb8jth9",
23
+ "Bbmb7ep": ["fqgqgel", "fchfifz"],
24
+ "Beyfa6y": ["fchfifz", "fqgqgel"],
25
+ "B7oj6ja": ["fc7b1hi", "f1dpx5h9"],
26
+ "Btl43ni": ["f1dpx5h9", "fc7b1hi"],
27
+ "De3pzq": "fxugw4r"
30
28
  },
31
29
  "statusBusy": {
32
- "De3pzq": "fdl5y0r",
33
- "g2u3we": "f11ttmz8",
34
- "h3c5rm": ["f1ratw88", "f459ikj"],
35
- "B9xav0g": "fvovscg",
36
- "zhjwy3": ["f459ikj", "f1ratw88"]
30
+ "sj55zd": "fvi85wt"
37
31
  },
38
32
  "statusAway": {
39
- "De3pzq": "fb00bxr",
40
- "g2u3we": "f1skk3ns",
41
- "h3c5rm": ["f766wml", "f1rnrfqa"],
42
- "B9xav0g": "fb8zvtn",
43
- "zhjwy3": ["f1rnrfqa", "f766wml"]
33
+ "sj55zd": "f14k8a89"
44
34
  },
45
35
  "statusAvailable": {
46
- "De3pzq": "f1og3d8b",
47
- "g2u3we": "f1t9i9vy",
48
- "h3c5rm": ["f1r5awo9", "fnfhfy0"],
49
- "B9xav0g": "fgfkvtu",
50
- "zhjwy3": ["fnfhfy0", "f1r5awo9"]
36
+ "sj55zd": "fqa5hgp"
51
37
  },
52
38
  "statusOffline": {
53
- "De3pzq": "fxugw4r",
54
- "sj55zd": "f11d4kpn",
55
- "g2u3we": "fi2z7s6",
56
- "h3c5rm": ["f1agc6it", "f1sit5hz"],
57
- "B9xav0g": "f9pok3v",
58
- "zhjwy3": ["f1sit5hz", "f1agc6it"]
39
+ "sj55zd": "f11d4kpn"
59
40
  },
60
41
  "statusOutOfOffice": {
61
- "De3pzq": "fxugw4r",
62
- "sj55zd": "fdce8r3",
63
- "g2u3we": "f161shwc",
64
- "h3c5rm": ["fbde6ui", "f7rrh46"],
65
- "B9xav0g": "f1yt3bcc",
66
- "zhjwy3": ["f7rrh46", "fbde6ui"]
42
+ "sj55zd": "fdce8r3"
67
43
  },
68
44
  "outOfOffice": {
69
- "De3pzq": "fxugw4r"
45
+ "sj55zd": "fr0bkrk"
70
46
  },
71
47
  "outOfOfficeAvailable": {
72
48
  "sj55zd": "fqa5hgp"
@@ -76,9 +52,27 @@ const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
76
52
  },
77
53
  "outOfOfficeAway": {
78
54
  "sj55zd": "f14k8a89"
55
+ },
56
+ "tiny": {
57
+ "Bubjx69": "f9ikmtg",
58
+ "a9b677": "f16dn6v3",
59
+ "B5pe6w7": "fab5kbq",
60
+ "p4uzdd": "f1ms1d91"
61
+ },
62
+ "large": {
63
+ "Bubjx69": "f9ikmtg",
64
+ "a9b677": "f64fuq3",
65
+ "B5pe6w7": "f1vfi1yj",
66
+ "p4uzdd": "f15s34gz"
67
+ },
68
+ "extraLarge": {
69
+ "Bubjx69": "f9ikmtg",
70
+ "a9b677": "f1w9dchk",
71
+ "B5pe6w7": "f14efy9b",
72
+ "p4uzdd": "fhipgdu"
79
73
  }
80
74
  }, {
81
- "d": [".f1g0x7ka{padding-top:0;}", ".fhxju0i{padding-right:0;}", ".f1cnd47f{padding-left:0;}", ".f1qch9an{padding-bottom:0;}", ".f18zi460{border-top-width:var(--strokeWidthThick);}", ".f1wpluaz{border-right-width:var(--strokeWidthThick);}", ".fsfsuhs{border-left-width:var(--strokeWidthThick);}", ".fmklw6v{border-bottom-width:var(--strokeWidthThick);}", ".f192inf7{border-top-width:var(--strokeWidthThin);}", ".f5tn483{border-right-width:var(--strokeWidthThin);}", ".f1ojsxk5{border-left-width:var(--strokeWidthThin);}", ".f1vxd6vx{border-bottom-width:var(--strokeWidthThin);}", ".fdl5y0r{background-color:var(--colorPaletteRedBackground3);}", ".f11ttmz8{border-top-color:var(--colorPaletteRedBackground3);}", ".f1ratw88{border-right-color:var(--colorPaletteRedBackground3);}", ".f459ikj{border-left-color:var(--colorPaletteRedBackground3);}", ".fvovscg{border-bottom-color:var(--colorPaletteRedBackground3);}", ".fb00bxr{background-color:var(--colorPaletteMarigoldBackground3);}", ".f1skk3ns{border-top-color:var(--colorPaletteMarigoldBackground3);}", ".f766wml{border-right-color:var(--colorPaletteMarigoldBackground3);}", ".f1rnrfqa{border-left-color:var(--colorPaletteMarigoldBackground3);}", ".fb8zvtn{border-bottom-color:var(--colorPaletteMarigoldBackground3);}", ".f1og3d8b{background-color:var(--colorPaletteLightGreenForeground3);}", ".f1t9i9vy{border-top-color:var(--colorPaletteLightGreenForeground3);}", ".f1r5awo9{border-right-color:var(--colorPaletteLightGreenForeground3);}", ".fnfhfy0{border-left-color:var(--colorPaletteLightGreenForeground3);}", ".fgfkvtu{border-bottom-color:var(--colorPaletteLightGreenForeground3);}", ".fxugw4r{background-color:var(--colorNeutralBackground1);}", ".f11d4kpn{color:var(--colorNeutralForeground3);}", ".fi2z7s6{border-top-color:var(--colorNeutralForeground3);}", ".f1agc6it{border-right-color:var(--colorNeutralForeground3);}", ".f1sit5hz{border-left-color:var(--colorNeutralForeground3);}", ".f9pok3v{border-bottom-color:var(--colorNeutralForeground3);}", ".fdce8r3{color:var(--colorPaletteBerryForeground3);}", ".f161shwc{border-top-color:var(--colorPaletteBerryForeground3);}", ".fbde6ui{border-right-color:var(--colorPaletteBerryForeground3);}", ".f7rrh46{border-left-color:var(--colorPaletteBerryForeground3);}", ".f1yt3bcc{border-bottom-color:var(--colorPaletteBerryForeground3);}", ".fqa5hgp{color:var(--colorPaletteLightGreenForeground3);}", ".fvi85wt{color:var(--colorPaletteRedBackground3);}", ".f14k8a89{color:var(--colorPaletteMarigoldBackground3);}"]
75
+ "d": [".f1g0x7ka{padding-top:0;}", ".fhxju0i{padding-right:0;}", ".f1cnd47f{padding-left:0;}", ".f1qch9an{padding-bottom:0;}", ".ftuwxu6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f1ewtqcl{box-sizing:border-box;}", ".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}", ".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}", ".fb8jth9 span{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}", ".fqgqgel{border-bottom-right-radius:50%;}", ".fchfifz{border-bottom-left-radius:50%;}", ".fc7b1hi{border-top-right-radius:50%;}", ".f1dpx5h9{border-top-left-radius:50%;}", ".fxugw4r{background-color:var(--colorNeutralBackground1);}", ".fvi85wt{color:var(--colorPaletteRedBackground3);}", ".f14k8a89{color:var(--colorPaletteMarigoldBackground3);}", ".fqa5hgp{color:var(--colorPaletteLightGreenForeground3);}", ".f11d4kpn{color:var(--colorNeutralForeground3);}", ".fdce8r3{color:var(--colorPaletteBerryForeground3);}", ".fr0bkrk{color:var(--colorNeutralBackground1);}", ".f9ikmtg{aspect-ratio:1;}", ".f16dn6v3{width:6px;}", ".fab5kbq svg{width:6px!important;}", ".f1ms1d91 svg{height:6px!important;}", ".f64fuq3{width:20px;}", ".f1vfi1yj svg{width:20px!important;}", ".f15s34gz svg{height:20px!important;}", ".f1w9dchk{width:28px;}", ".f14efy9b svg{width:28px!important;}", ".fhipgdu svg{height:28px!important;}"]
82
76
  });
83
77
  /**
84
78
  * Applies style classnames to slots
@@ -87,8 +81,8 @@ const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
87
81
 
88
82
  const usePresenceBadgeStyles = state => {
89
83
  const styles = useStyles();
90
- state.root.className = react_make_styles_1.mergeClasses(exports.presenceBadgeClassName, styles.root, (state.status === 'busy' || state.status === 'doNotDisturb') && styles.statusBusy, state.status === 'away' && styles.statusAway, state.status === 'available' && styles.statusAvailable, state.status === 'offline' && styles.statusOffline, state.status === 'outOfOffice' && styles.statusOutOfOffice, state.outOfOffice && styles.outOfOffice, state.outOfOffice && state.status === 'available' && styles.outOfOfficeAvailable, state.outOfOffice && (state.status === 'busy' || state.status === 'doNotDisturb') && styles.outOfOfficeBusy, state.outOfOffice && state.status === 'away' && styles.outOfOfficeAway, (state.size === 'tiny' || state.size === 'extra-small') && styles.thinBorder, state.root.className);
91
- return Badge_1.useBadgeStyles(state);
84
+ state.root.className = react_make_styles_1.mergeClasses(exports.presenceBadgeClassName, styles.root, (state.status === 'busy' || state.status === 'doNotDisturb') && styles.statusBusy, state.status === 'away' && styles.statusAway, state.status === 'available' && styles.statusAvailable, state.status === 'offline' && styles.statusOffline, state.status === 'outOfOffice' && styles.statusOutOfOffice, state.outOfOffice && styles.outOfOffice, state.outOfOffice && state.status === 'available' && styles.outOfOfficeAvailable, state.outOfOffice && (state.status === 'busy' || state.status === 'doNotDisturb') && styles.outOfOfficeBusy, state.outOfOffice && state.status === 'away' && styles.outOfOfficeAway, state.outOfOffice && state.status === 'offline' && styles.statusOffline, state.outOfOffice && state.status === 'outOfOffice' && styles.statusOutOfOffice, state.size === 'tiny' && styles.tiny, state.size === 'large' && styles.large, state.size === 'extra-large' && styles.extraLarge, state.root.className);
85
+ return state;
92
86
  };
93
87
 
94
88
  exports.usePresenceBadgeStyles = usePresenceBadgeStyles;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/PresenceBadge/usePresenceBadgeStyles.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,mBAAA,gBAAA,OAAA,CAAA,6BAAA,CAAA;;AACA,MAAA,OAAA,gBAAA,OAAA,CAAA,aAAA,CAAA;;AAGa,OAAA,CAAA,sBAAA,GAAyB,mBAAzB;;AAEb,MAAM,SAAS,gBAAG,mBAAA,SAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AA4CA;;AAEG;;;AACI,MAAM,sBAAsB,GAAI,KAAD,IAAkD;AACtF,QAAM,MAAM,GAAG,SAAS,EAAxB;AACA,EAAA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,mBAAA,CAAA,YAAA,CACrB,OAAA,CAAA,sBADqB,EAErB,MAAM,CAAC,IAFc,EAGrB,CAAC,KAAK,CAAC,MAAN,KAAiB,MAAjB,IAA2B,KAAK,CAAC,MAAN,KAAiB,cAA7C,KAAgE,MAAM,CAAC,UAHlD,EAIrB,KAAK,CAAC,MAAN,KAAiB,MAAjB,IAA2B,MAAM,CAAC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AC,aAZrC,EAarB,KAAK,CAAC,WAAN,IAAqB,KAAK,CAAC,MAAN,KAAiB,aAAtC,IAAuD,MAAM,CAAC,iBAbzC,EAcrB,KAAK,CAAC,IAAN,KAAe,MAAf,IAAyB,MAAM,CAAC,IAdX,EAerB,KAAK,CAAC,IAAN,KAAe,OAAf,IAA0B,MAAM,CAAC,KAfZ,EAgBrB,KAAK,CAAC,IAAN,KAAe,aAAf,IAAgC,MAAM,CAAC,UAhBlB,EAiBrB,KAAK,CAAC,IAAN,CAAW,SAjBU,CAAvB;AAoBA,SAAO,KAAP;AACD,CAvBM;;AAAM,OAAA,CAAA,sBAAA,GAAsB,sBAAtB","sourceRoot":""}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui/react-badge",
3
- "version": "0.0.0-nightlybc5ff01fb020211104.1",
3
+ "version": "0.0.0-nightlycc44f3625c20211220.1",
4
4
  "description": "React components for building web experiences",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",
@@ -21,15 +21,16 @@
21
21
  "start": "yarn storybook",
22
22
  "test": "jest",
23
23
  "docs": "api-extractor run --config=config/api-extractor.local.json --local",
24
- "build:local": "tsc -p . --module esnext --emitDeclarationOnly && node ../../scripts/typescript/normalize-import --output dist/react-badge/src && yarn docs",
25
- "storybook": "start-storybook"
24
+ "build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../scripts/typescript/normalize-import --output ./dist/packages/react-badge/src && yarn docs",
25
+ "storybook": "start-storybook",
26
+ "type-check": "tsc -b tsconfig.json"
26
27
  },
27
28
  "devDependencies": {
28
- "@fluentui/babel-make-styles": "0.0.0-nightlybc5ff01fb020211104.1",
29
+ "@fluentui/babel-make-styles": "0.0.0-nightlycc44f3625c20211220.1",
29
30
  "@fluentui/eslint-plugin": "*",
30
- "@fluentui/jest-serializer-make-styles": "0.0.0-nightlybc5ff01fb020211104.1",
31
+ "@fluentui/jest-serializer-make-styles": "0.0.0-nightlycc44f3625c20211220.1",
31
32
  "@fluentui/react-conformance": "*",
32
- "@fluentui/react-conformance-make-styles": "0.0.0-nightlybc5ff01fb020211104.1",
33
+ "@fluentui/react-conformance-make-styles": "0.0.0-nightlycc44f3625c20211220.1",
33
34
  "@fluentui/scripts": "^1.0.0",
34
35
  "@types/enzyme": "3.10.3",
35
36
  "@types/enzyme-adapter-react-16": "1.0.3",
@@ -43,9 +44,10 @@
43
44
  "react-test-renderer": "^16.3.0"
44
45
  },
45
46
  "dependencies": {
46
- "@fluentui/react-make-styles": "0.0.0-nightlybc5ff01fb020211104.1",
47
- "@fluentui/react-theme": "0.0.0-nightlybc5ff01fb020211104.1",
48
- "@fluentui/react-utilities": "0.0.0-nightlybc5ff01fb020211104.1",
47
+ "@fluentui/react-icons": "^2.0.154-beta.5",
48
+ "@fluentui/react-make-styles": "0.0.0-nightlycc44f3625c20211220.1",
49
+ "@fluentui/react-theme": "0.0.0-nightlycc44f3625c20211220.1",
50
+ "@fluentui/react-utilities": "0.0.0-nightlycc44f3625c20211220.1",
49
51
  "tslib": "^2.1.0"
50
52
  },
51
53
  "peerDependencies": {
@@ -55,7 +57,6 @@
55
57
  "react-dom": ">=16.8.0 <17.0.0"
56
58
  },
57
59
  "beachball": {
58
- "tag": "beta",
59
60
  "disallowedChangeTypes": [
60
61
  "major",
61
62
  "minor",
@@ -1,4 +0,0 @@
1
- import type { IsConformantOptions } from '@fluentui/react-conformance';
2
- export declare function isConformant<TProps = {}>(testInfo: Omit<IsConformantOptions<TProps>, 'componentPath'> & {
3
- componentPath?: string;
4
- }): void;
@@ -1,13 +0,0 @@
1
- import { isConformant as baseIsConformant } from '@fluentui/react-conformance';
2
- import makeStylesTests from '@fluentui/react-conformance-make-styles';
3
- export function isConformant(testInfo) {
4
- const defaultOptions = {
5
- asPropHandlesRef: true,
6
- componentPath: module.parent.filename.replace('.test', ''),
7
- // https://github.com/microsoft/fluentui/issues/19522
8
- skipAsPropTests: true,
9
- extraTests: makeStylesTests
10
- };
11
- baseIsConformant(defaultOptions, testInfo);
12
- }
13
- //# sourceMappingURL=isConformant.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/common/isConformant.ts"],"names":[],"mappings":"AAAA,SAAS,YAAY,IAAI,gBAAzB,QAAiD,6BAAjD;AACA,OAAO,eAAP,MAA4B,yCAA5B;AAGA,OAAM,SAAU,YAAV,CACJ,QADI,EACqF;AAEzF,QAAM,cAAc,GAAyC;AAC3D,IAAA,gBAAgB,EAAE,IADyC;AAE3D,IAAA,aAAa,EAAE,MAAO,CAAC,MAAR,CAAgB,QAAhB,CAAyB,OAAzB,CAAiC,OAAjC,EAA0C,EAA1C,CAF4C;AAG3D;AACA,IAAA,eAAe,EAAE,IAJ0C;AAK3D,IAAA,UAAU,EAAE;AAL+C,GAA7D;AAQA,EAAA,gBAAgB,CAAC,cAAD,EAAiB,QAAjB,CAAhB;AACD","sourceRoot":""}
@@ -1,10 +0,0 @@
1
- import * as React from 'react';
2
- export declare const renderIcon: (SVGElement: (props: {
3
- svgClasses: string;
4
- }) => JSX.Element) => React.FC<React.HTMLAttributes<HTMLSpanElement>>;
5
- declare const SkypeMinusIcon: React.FC<React.HTMLAttributes<HTMLSpanElement>>;
6
- declare const SkypeClockIcon: React.FC<React.HTMLAttributes<HTMLSpanElement>>;
7
- declare const SkypeCheckIcon: React.FC<React.HTMLAttributes<HTMLSpanElement>>;
8
- declare const SkypeArrowIcon: React.FC<React.HTMLAttributes<HTMLSpanElement>>;
9
- declare const CancelIcon: React.FC<React.HTMLAttributes<HTMLSpanElement>>;
10
- export { SkypeMinusIcon, SkypeClockIcon, SkypeCheckIcon, SkypeArrowIcon, CancelIcon };