@nextelco/common-ui 2.1.2 → 2.1.4

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.
@@ -4,12 +4,14 @@ interface Props {
4
4
  name?: string | null;
5
5
  email?: string | null;
6
6
  className?: string;
7
+ /** Passa para UserAvatar: cartão de detalhes em hover. Default: off. */
8
+ showCard?: boolean;
7
9
  }
8
10
  /**
9
11
  * Avatar com a foto real do MS Graph (por oid). Fallback: iniciais (UserAvatar).
10
12
  * O token do Graph é obtido via MSAL (`useMsal`) da app consumidora.
11
13
  *
12
- * Peers necessários: @azure/msal-react, @azure/msal-browser, @tanstack/react-query.
14
+ * Peers necessários: @azure/msal-react, @azure/msal-browser.
13
15
  */
14
- export default function PhotoAvatar({ oid, name, email, className }: Props): React.JSX.Element;
16
+ export default function PhotoAvatar({ oid, name, email, className, showCard }: Props): React.JSX.Element;
15
17
  export {};
@@ -7,11 +7,13 @@ interface UserAvatarProps {
7
7
  jobTitle?: string | null;
8
8
  department?: string | null;
9
9
  className?: string;
10
+ /** Mostra o cartão de detalhes em hover (foto ampliada + nome/email). Default: off. */
11
+ showCard?: boolean;
10
12
  }
11
13
  /**
12
14
  * Avatar de utilizador: mostra a foto (se disponível) ou as iniciais, com um
13
15
  * cartão de detalhes em hover (via portal). Usa classes Tailwind — a app
14
16
  * consumidora é responsável por gerar o CSS Tailwind.
15
17
  */
16
- export default function UserAvatar({ name, photo, email, company, jobTitle, department, className, }: UserAvatarProps): React.JSX.Element;
18
+ export default function UserAvatar({ name, photo, email, company, jobTitle, department, className, showCard, }: UserAvatarProps): React.JSX.Element;
17
19
  export {};
package/package.json CHANGED
@@ -1,90 +1,85 @@
1
- {
2
- "name": "@nextelco/common-ui",
3
- "version": "2.1.2",
4
- "description": "",
5
- "main": "dist/bundle.js",
6
- "types": "dist/types/index.d.ts",
7
- "files": [
8
- "dist"
9
- ],
10
- "scripts": {
11
- "build": "webpack --mode production",
12
- "storybook": "storybook dev -p 6006",
13
- "build-storybook": "storybook build",
14
- "pub": "git add . && git commit -m \"update\" && git push && npm version patch && npm run build && npm publish",
15
- "pubOnly": "npm version patch && npm run build && npm publish",
16
- "pubOnlySameVersion": "npm run build && npm publish"
17
- },
18
- "keywords": [],
19
- "author": "",
20
- "license": "ISC",
21
- "peerDependencies": {
22
- "@azure/msal-browser": ">=3",
23
- "@azure/msal-react": ">=2",
24
- "@tanstack/react-query": ">=5",
25
- "react": "^18.3.1",
26
- "react-dom": "^18.3.1",
27
- "react-router-dom": ">=6"
28
- },
29
- "peerDependenciesMeta": {
30
- "@azure/msal-react": {
31
- "optional": true
32
- },
33
- "@azure/msal-browser": {
34
- "optional": true
35
- },
36
- "@tanstack/react-query": {
37
- "optional": true
38
- }
39
- },
40
- "devDependencies": {
41
- "@azure/msal-browser": "^5.17.3",
42
- "@azure/msal-react": "^5.5.4",
43
- "@chromatic-com/storybook": "^4.0.0",
44
- "@storybook/addon-docs": "^9.0.0",
45
- "@storybook/addon-interactions": "^8.6.14",
46
- "@storybook/addon-links": "^9.0.0",
47
- "@storybook/addon-onboarding": "^9.0.0",
48
- "@storybook/addon-webpack5-compiler-babel": "^3.0.6",
49
- "@storybook/addon-webpack5-compiler-swc": "^3.0.0",
50
- "@storybook/react-webpack5": "^9.0.0",
51
- "@tanstack/react-query": "^5.101.4",
52
- "@types/js-cookie": "^3.0.6",
53
- "@types/react": "^19.0.8",
54
- "@types/react-dom": "^19.0.3",
55
- "@types/socket.io-client": "^3.0.0",
56
- "@types/storybook__react": "^5.2.1",
57
- "css-loader": "^7.1.2",
58
- "msw": "^2.7.3",
59
- "react-router-dom": "^6.30.4",
60
- "sass": "^1.84.0",
61
- "sass-loader": "^16.0.4",
62
- "storybook": "^9.0.0",
63
- "style-loader": "^4.0.0",
64
- "ts-loader": "^9.5.2",
65
- "typescript": "^5.7.3",
66
- "webpack": "^5.97.1",
67
- "webpack-cli": "^6.0.1"
68
- },
69
- "dependencies": {
70
- "@fortawesome/fontawesome-svg-core": "^6.7.2",
71
- "@fortawesome/free-brands-svg-icons": "^6.7.2",
72
- "@fortawesome/free-regular-svg-icons": "^6.7.2",
73
- "@fortawesome/free-solid-svg-icons": "^6.7.2",
74
- "@fortawesome/react-fontawesome": "^0.2.2",
75
- "axios": "^1.8.1",
76
- "iconoir-react": "^7.11.0",
77
- "js-cookie": "^3.0.5",
78
- "keycloak-js": "^25.0.0",
79
- "react-focus-lock": "^2.13.6",
80
- "react-infinite-scroll-component": "^6.1.0",
81
- "react-remove-scroll": "^2.6.3",
82
- "react-switch": "^7.1.0",
83
- "react-tooltip": "^5.28.0",
84
- "socket.io-client": "^4.8.1",
85
- "tough-cookie": "^5.1.2"
86
- },
87
- "overrides": {
88
- "storybook": "$storybook"
89
- }
90
- }
1
+ {
2
+ "name": "@nextelco/common-ui",
3
+ "version": "2.1.4",
4
+ "description": "",
5
+ "main": "dist/bundle.js",
6
+ "types": "dist/types/index.d.ts",
7
+ "files": [
8
+ "dist"
9
+ ],
10
+ "scripts": {
11
+ "build": "webpack --mode production",
12
+ "storybook": "storybook dev -p 6006",
13
+ "build-storybook": "storybook build",
14
+ "pub": "git add . && git commit -m \"update\" && git push && npm version patch && npm run build && npm publish",
15
+ "pubOnly": "npm version patch && npm run build && npm publish",
16
+ "pubOnlySameVersion": "npm run build && npm publish"
17
+ },
18
+ "keywords": [],
19
+ "author": "",
20
+ "license": "ISC",
21
+ "peerDependencies": {
22
+ "@azure/msal-browser": ">=3",
23
+ "@azure/msal-react": ">=2",
24
+ "react": "^18.3.1",
25
+ "react-dom": "^18.3.1",
26
+ "react-router-dom": ">=6"
27
+ },
28
+ "peerDependenciesMeta": {
29
+ "@azure/msal-react": {
30
+ "optional": true
31
+ },
32
+ "@azure/msal-browser": {
33
+ "optional": true
34
+ }
35
+ },
36
+ "devDependencies": {
37
+ "@azure/msal-browser": "^5.17.3",
38
+ "@azure/msal-react": "^5.5.4",
39
+ "@chromatic-com/storybook": "^4.0.0",
40
+ "@storybook/addon-docs": "^9.0.0",
41
+ "@storybook/addon-interactions": "^8.6.14",
42
+ "@storybook/addon-links": "^9.0.0",
43
+ "@storybook/addon-onboarding": "^9.0.0",
44
+ "@storybook/addon-webpack5-compiler-babel": "^3.0.6",
45
+ "@storybook/addon-webpack5-compiler-swc": "^3.0.0",
46
+ "@storybook/react-webpack5": "^9.0.0",
47
+ "@types/js-cookie": "^3.0.6",
48
+ "@types/react": "^19.0.8",
49
+ "@types/react-dom": "^19.0.3",
50
+ "@types/socket.io-client": "^3.0.0",
51
+ "@types/storybook__react": "^5.2.1",
52
+ "css-loader": "^7.1.2",
53
+ "msw": "^2.7.3",
54
+ "react-router-dom": "^6.30.4",
55
+ "sass": "^1.84.0",
56
+ "sass-loader": "^16.0.4",
57
+ "storybook": "^9.0.0",
58
+ "style-loader": "^4.0.0",
59
+ "ts-loader": "^9.5.2",
60
+ "typescript": "^5.7.3",
61
+ "webpack": "^5.97.1",
62
+ "webpack-cli": "^6.0.1"
63
+ },
64
+ "dependencies": {
65
+ "@fortawesome/fontawesome-svg-core": "^6.7.2",
66
+ "@fortawesome/free-brands-svg-icons": "^6.7.2",
67
+ "@fortawesome/free-regular-svg-icons": "^6.7.2",
68
+ "@fortawesome/free-solid-svg-icons": "^6.7.2",
69
+ "@fortawesome/react-fontawesome": "^0.2.2",
70
+ "axios": "^1.8.1",
71
+ "iconoir-react": "^7.11.0",
72
+ "js-cookie": "^3.0.5",
73
+ "keycloak-js": "^25.0.0",
74
+ "react-focus-lock": "^2.13.6",
75
+ "react-infinite-scroll-component": "^6.1.0",
76
+ "react-remove-scroll": "^2.6.3",
77
+ "react-switch": "^7.1.0",
78
+ "react-tooltip": "^5.28.0",
79
+ "socket.io-client": "^4.8.1",
80
+ "tough-cookie": "^5.1.2"
81
+ },
82
+ "overrides": {
83
+ "storybook": "$storybook"
84
+ }
85
+ }