From b33b4990d125c077c65190de99ebec9b43e4e948 Mon Sep 17 00:00:00 2001 From: AlexeySafronov Date: Tue, 9 Mar 2021 13:58:03 +0300 Subject: [PATCH 1/2] Web: Login: fix register empty render --- .../src/sub-components/register-container.js | 41 ++-- yarn.lock | 228 +++++++++--------- 2 files changed, 137 insertions(+), 132 deletions(-) diff --git a/web/ASC.Web.Login/src/sub-components/register-container.js b/web/ASC.Web.Login/src/sub-components/register-container.js index 5130cf0afa..db474f768d 100644 --- a/web/ASC.Web.Login/src/sub-components/register-container.js +++ b/web/ASC.Web.Login/src/sub-components/register-container.js @@ -66,28 +66,27 @@ const Register = (props) => { } }; - return ( - enabledJoin && - !isAuthenticated && ( - <> - - {t("Register")} - + return enabledJoin && !isAuthenticated ? ( + <> + + {t("Register")} + - {visible && ( - - )} - - ) + {visible && ( + + )} + + ) : ( + <> ); }; diff --git a/yarn.lock b/yarn.lock index e5edd3053b..83754ad6d9 100644 --- a/yarn.lock +++ b/yarn.lock @@ -11,9 +11,9 @@ warning "^4.0.3" "@babel/cli@^7.12.10": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.13.0.tgz#48e77614e897615ca299bece587b68a70723ff4c" - integrity sha512-y5AohgeVhU+wO5kU1WGMLdocFj83xCxVjsVFa2ilII8NEwmBZvx7Ambq621FbFIK68loYJ9p43nfoi6es+rzSA== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/cli/-/cli-7.13.10.tgz#3a9254cbe806639c8ca4ebd49ebe54b4267b88c9" + integrity sha512-lYSBC7B4B9hJ7sv0Ojx1BrGhuzCoOIYfLjd+Xpd4rOzdS+a47yi8voV8vFkfjlZR1N5qZO7ixOCbobUdT304PQ== dependencies: commander "^4.0.1" convert-source-map "^1.1.0" @@ -91,16 +91,16 @@ source-map "^0.5.0" "@babel/core@^7.1.0", "@babel/core@^7.11.1", "@babel/core@^7.12.1", "@babel/core@^7.12.10", "@babel/core@^7.12.3", "@babel/core@^7.7.5": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.13.8.tgz#c191d9c5871788a591d69ea1dc03e5843a3680fb" - integrity sha512-oYapIySGw1zGhEFRd6lzWNLWFX2s5dA/jm+Pw/+59ZdXtjyIuwlXbrId22Md0rgZVop+aVoqow2riXhBLNyuQg== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.13.10.tgz#07de050bbd8193fcd8a3c27918c0890613a94559" + integrity sha512-bfIYcT0BdKeAZrovpMqX2Mx5NrgAckGbwT982AkdS5GNfn3KMGiprlBAtmBcFZRUmpaufS6WZFP8trvx8ptFDw== dependencies: "@babel/code-frame" "^7.12.13" - "@babel/generator" "^7.13.0" - "@babel/helper-compilation-targets" "^7.13.8" + "@babel/generator" "^7.13.9" + "@babel/helper-compilation-targets" "^7.13.10" "@babel/helper-module-transforms" "^7.13.0" - "@babel/helpers" "^7.13.0" - "@babel/parser" "^7.13.4" + "@babel/helpers" "^7.13.10" + "@babel/parser" "^7.13.10" "@babel/template" "^7.12.13" "@babel/traverse" "^7.13.0" "@babel/types" "^7.13.0" @@ -112,7 +112,7 @@ semver "^6.3.0" source-map "^0.5.0" -"@babel/generator@^7.12.1", "@babel/generator@^7.12.5", "@babel/generator@^7.13.0", "@babel/generator@^7.4.0", "@babel/generator@^7.9.0": +"@babel/generator@^7.12.1", "@babel/generator@^7.12.5", "@babel/generator@^7.13.0", "@babel/generator@^7.13.9", "@babel/generator@^7.4.0", "@babel/generator@^7.9.0": version "7.13.9" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.13.9.tgz#3a7aa96f9efb8e2be42d38d80e2ceb4c64d8de39" integrity sha512-mHOOmY0Axl/JCTkxTU6Lf5sWOg/v8nUa+Xkt4zMTftX0wqmb6Sh7J8gvcehBw7q0AhrhAR+FDacKjCZ2X8K+Sw== @@ -136,10 +136,10 @@ "@babel/helper-explode-assignable-expression" "^7.12.13" "@babel/types" "^7.12.13" -"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.13.8", "@babel/helper-compilation-targets@^7.8.7": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.8.tgz#02bdb22783439afb11b2f009814bdd88384bd468" - integrity sha512-pBljUGC1y3xKLn1nrx2eAhurLMA8OqBtBP/JwG4U8skN7kf8/aqwwxpV1N6T0e7r6+7uNitIa/fUxPFagSXp3A== +"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.13.10", "@babel/helper-compilation-targets@^7.13.8", "@babel/helper-compilation-targets@^7.8.7": + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.10.tgz#1310a1678cb8427c07a753750da4f8ce442bdd0c" + integrity sha512-/Xju7Qg1GQO4mHZ/Kcs6Au7gfafgZnwm+a7sy/ow/tV1sHeraRUHbjdat8/UvDor4Tez+siGKDk6zIKtCPKVJA== dependencies: "@babel/compat-data" "^7.13.8" "@babel/helper-validator-option" "^7.12.17" @@ -147,9 +147,9 @@ semver "^6.3.0" "@babel/helper-create-class-features-plugin@^7.13.0", "@babel/helper-create-class-features-plugin@^7.8.3": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.13.8.tgz#0367bd0a7505156ce018ca464f7ac91ba58c1a04" - integrity sha512-qioaRrKHQbn4hkRKDHbnuQ6kAxmmOF+kzKGnIfxPK4j2rckSJCpKzr/SSTlohSCiE3uAQpNDJ9FIh4baeE8W+w== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.13.10.tgz#073b2bbb925a097643c6fc5770e5f13394e887c9" + integrity sha512-YV7r2YxdTUaw84EwNkyrRke/TJHR/UXGiyvACRqvdVJ2/syV2rQuJNnaRLSuYiop8cMRXOgseTGoJCWX0q2fFg== dependencies: "@babel/helper-function-name" "^7.12.13" "@babel/helper-member-expression-to-functions" "^7.13.0" @@ -316,28 +316,28 @@ "@babel/traverse" "^7.13.0" "@babel/types" "^7.13.0" -"@babel/helpers@^7.12.5", "@babel/helpers@^7.13.0", "@babel/helpers@^7.9.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.13.0.tgz#7647ae57377b4f0408bf4f8a7af01c42e41badc0" - integrity sha512-aan1MeFPxFacZeSz6Ld7YZo5aPuqnKlD7+HZY75xQsueczFccP9A7V05+oe0XpLwHK3oLorPe9eaAUljL7WEaQ== +"@babel/helpers@^7.12.5", "@babel/helpers@^7.13.10", "@babel/helpers@^7.9.0": + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.13.10.tgz#fd8e2ba7488533cdeac45cc158e9ebca5e3c7df8" + integrity sha512-4VO883+MWPDUVRF3PhiLBUFHoX/bsLTGFpFK/HqvvfBZz2D57u9XzPVNFVBTc0PW/CWR9BXTOKt8NF4DInUHcQ== dependencies: "@babel/template" "^7.12.13" "@babel/traverse" "^7.13.0" "@babel/types" "^7.13.0" "@babel/highlight@^7.10.4", "@babel/highlight@^7.12.13": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.13.8.tgz#10b2dac78526424dfc1f47650d0e415dfd9dc481" - integrity sha512-4vrIhfJyfNf+lCtXC2ck1rKSzDwciqF7IWFhXXrSOUC2O5DrVp+w4c6ed4AllTxhTkUP5x2tYj41VaxdVMMRDw== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.13.10.tgz#a8b2a66148f5b27d666b15d81774347a731d52d1" + integrity sha512-5aPpe5XQPzflQrFwL1/QoeHkP2MsA4JCntcXHRhEsdsfPVkvPi2w7Qix4iV7t5S/oC9OodGrggd8aco1g3SZFg== dependencies: "@babel/helper-validator-identifier" "^7.12.11" chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/parser@^7.0.0", "@babel/parser@^7.1.0", "@babel/parser@^7.12.13", "@babel/parser@^7.12.3", "@babel/parser@^7.12.7", "@babel/parser@^7.13.0", "@babel/parser@^7.13.4", "@babel/parser@^7.4.3", "@babel/parser@^7.7.0", "@babel/parser@^7.9.0": - version "7.13.9" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.13.9.tgz#ca34cb95e1c2dd126863a84465ae8ef66114be99" - integrity sha512-nEUfRiARCcaVo3ny3ZQjURjHQZUo/JkEw7rLlSZy/psWGnvwXFtPcr6jb7Yb41DVW5LTe6KRq9LGleRNsg1Frw== +"@babel/parser@^7.0.0", "@babel/parser@^7.1.0", "@babel/parser@^7.12.13", "@babel/parser@^7.12.3", "@babel/parser@^7.12.7", "@babel/parser@^7.13.0", "@babel/parser@^7.13.10", "@babel/parser@^7.4.3", "@babel/parser@^7.7.0", "@babel/parser@^7.9.0": + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.13.10.tgz#8f8f9bf7b3afa3eabd061f7a5bcdf4fec3c48409" + integrity sha512-0s7Mlrw9uTWkYua7xWr99Wpk2bnGa0ANleKfksYAES8LpWH4gW1OUr42vqKNf0us5UQNfru2wPqMqRITzq/SIQ== "@babel/plugin-proposal-async-generator-functions@^7.13.8", "@babel/plugin-proposal-async-generator-functions@^7.8.3": version "7.13.8" @@ -841,11 +841,11 @@ "@babel/helper-plugin-utils" "^7.12.13" "@babel/plugin-transform-react-constant-elements@^7.12.1": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.12.13.tgz#f8ee56888545d53d80f766b3cc1563ab2c241f92" - integrity sha512-qmzKVTn46Upvtxv8LQoQ8mTCdUC83AOVQIQm57e9oekLT5cmK9GOMOfcWhe8jMNx4UJXn/UDhVZ/7lGofVNeDQ== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.13.10.tgz#5d3de8a8ee53f4612e728f4f17b8c9125f8019e5" + integrity sha512-E+aCW9j7mLq01tOuGV08YzLBt+vSyr4bOPT75B6WrAlrUfmOYOZ/yWk847EH0dv0xXiCihWLEmlX//O30YhpIw== dependencies: - "@babel/helper-plugin-utils" "^7.12.13" + "@babel/helper-plugin-utils" "^7.13.0" "@babel/plugin-transform-react-display-name@7.8.3": version "7.8.3" @@ -926,9 +926,9 @@ semver "^5.5.1" "@babel/plugin-transform-runtime@^7.12.1", "@babel/plugin-transform-runtime@^7.12.10", "@babel/plugin-transform-runtime@^7.13.9": - version "7.13.9" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.13.9.tgz#744d3103338a0d6c90dee0497558150b490cee07" - integrity sha512-XCxkY/wBI6M6Jj2mlWxkmqbKPweRanszWbF3Tyut+hKh+PHcuIH/rSr/7lmmE7C3WW+HSIm2GT+d5jwmheuB0g== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.13.10.tgz#a1e40d22e2bf570c591c9c7e5ab42d6bf1e419e1" + integrity sha512-Y5k8ipgfvz5d/76tx7JYbKQTcgFSU6VgJ3kKQv4zGTKr+a9T/KBvfRvGtSFgKDQGt/DBykQixV0vNWKIdzWErA== dependencies: "@babel/helper-module-imports" "^7.12.13" "@babel/helper-plugin-utils" "^7.13.0" @@ -1064,12 +1064,12 @@ semver "^5.5.0" "@babel/preset-env@^7.11.0", "@babel/preset-env@^7.12.1", "@babel/preset-env@^7.12.11", "@babel/preset-env@^7.12.7", "@babel/preset-env@^7.13.9": - version "7.13.9" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.13.9.tgz#3ee5f233316b10d066d7f379c6d1e13a96853654" - integrity sha512-mcsHUlh2rIhViqMG823JpscLMesRt3QbMsv1+jhopXEb3W2wXvQ9QoiOlZI9ZbR3XqPtaFpZwEZKYqGJnGMZTQ== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.13.10.tgz#b5cde31d5fe77ab2a6ab3d453b59041a1b3a5252" + integrity sha512-nOsTScuoRghRtUsRr/c69d042ysfPHcu+KOB4A9aAO9eJYqrkat+LF8G1yp1HD18QiwixT2CisZTr/0b3YZPXQ== dependencies: "@babel/compat-data" "^7.13.8" - "@babel/helper-compilation-targets" "^7.13.8" + "@babel/helper-compilation-targets" "^7.13.10" "@babel/helper-plugin-utils" "^7.13.0" "@babel/helper-validator-option" "^7.12.17" "@babel/plugin-proposal-async-generator-functions" "^7.13.8" @@ -1208,9 +1208,9 @@ source-map-support "^0.5.16" "@babel/runtime-corejs3@^7.10.2": - version "7.13.9" - resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.13.9.tgz#b2fa9a6e5690ef8d4c4f2d30cac3ec1a8bb633ce" - integrity sha512-p6WSr71+5u/VBf1KDS/Y4dK3ZwbV+DD6wQO3X2EbUVluEOiyXUk09DzcwSaUH4WomYXrEPC+i2rqzuthhZhOJw== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.13.10.tgz#14c3f4c85de22ba88e8e86685d13e8861a82fe86" + integrity sha512-x/XYVQ1h684pp1mJwOV4CyvqZXqbc8CMsMGUnAbuc82ZCdv1U63w5RSUzgDSXQHG5Rps/kiksH6g2D5BuaKyXg== dependencies: core-js-pure "^3.0.0" regenerator-runtime "^0.13.4" @@ -1223,9 +1223,9 @@ regenerator-runtime "^0.13.4" "@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.2", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.0", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.13", "@babel/runtime@^7.12.18", "@babel/runtime@^7.12.5", "@babel/runtime@^7.13.6", "@babel/runtime@^7.13.9", "@babel/runtime@^7.3.1", "@babel/runtime@^7.4.2", "@babel/runtime@^7.5.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.8.7", "@babel/runtime@^7.9.2": - version "7.13.9" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.13.9.tgz#97dbe2116e2630c489f22e0656decd60aaa1fcee" - integrity sha512-aY2kU+xgJ3dJ1eU6FMB9EH8dIe8dmusF1xEku52joLvw6eAFN0AI+WxCLDnpev2LEejWBAy2sBvBOBAjI3zmvA== + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.13.10.tgz#47d42a57b6095f4468da440388fdbad8bebf0d7d" + integrity sha512-4QPkjJq6Ns3V/RgpEahRk+AGfL0eO6RHHtTWoNNr5mO49G6B5+X6d6THgWEAvTrznU5xYpbAlVKRYcsCgh/Akw== dependencies: regenerator-runtime "^0.13.4" @@ -2535,10 +2535,10 @@ is-plain-object "^5.0.0" universal-user-agent "^6.0.0" -"@octokit/openapi-types@^5.3.0": - version "5.3.1" - resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-5.3.1.tgz#a49d119a1b9e47b7a9f5133ab14be2d8afaa183d" - integrity sha512-TvVk2QuIA0lQZcIMd6xbdGaGDVeNYIOa3l1ZVagAIk5K3t/WMYbcg4BISNDhzdVhm/TgQB26frAgd/GV81aHJA== +"@octokit/openapi-types@^5.3.2": + version "5.3.2" + resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-5.3.2.tgz#b8ac43c5c3d00aef61a34cf744e315110c78deb4" + integrity sha512-NxF1yfYOUO92rCx3dwvA2onF30Vdlg7YUkMVXkeptqpzA3tRLplThhFleV/UKWFgh7rpKu1yYRbvNDUtzSopKA== "@octokit/plugin-enterprise-rest@^6.0.1": version "6.0.1" @@ -2627,11 +2627,11 @@ "@types/node" ">= 8" "@octokit/types@^6.0.3", "@octokit/types@^6.7.1": - version "6.12.0" - resolved "https://registry.yarnpkg.com/@octokit/types/-/types-6.12.0.tgz#8376fd60edfd5d1eebfeedb994c6bcb5b862c7a1" - integrity sha512-KwOf16soD7aDEEi/PgNeJlHzjZPfrmmNy+7WezSdrpnqZ7YImBJcNnX9+5RUHt1MnA4h8oISRHTqaZDGsX9DRQ== + version "6.12.2" + resolved "https://registry.yarnpkg.com/@octokit/types/-/types-6.12.2.tgz#5b44add079a478b8eb27d78cf384cc47e4411362" + integrity sha512-kCkiN8scbCmSq+gwdJV0iLgHc0O/GTPY1/cffo9kECu1MvatLPh9E+qFhfRIktKfHEA6ZYvv6S1B4Wnv3bi3pA== dependencies: - "@octokit/openapi-types" "^5.3.0" + "@octokit/openapi-types" "^5.3.2" "@pmmmwh/react-refresh-webpack-plugin@^0.4.2": version "0.4.3" @@ -2646,9 +2646,9 @@ source-map "^0.7.3" "@popperjs/core@^2.5.4": - version "2.9.0" - resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.9.0.tgz#32e63212293dd3efbb521cd35a5020ab66eaa546" - integrity sha512-wjtKehFAIARq2OxK8j3JrggNlEslJfNuSm2ArteIbKyRMts2g0a7KzTxfRVNUM+O0gnBJ2hNV8nWPOYBgI1sew== + version "2.9.1" + resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.9.1.tgz#7f554e7368c9ab679a11f4a042ca17149d70cf12" + integrity sha512-DvJbbn3dUgMxDnJLH+RZQPnXak1h4ZVYQ7CWiFWjQwBFkVajT4rfw2PdpHLTSTwxrYfnoEXkuBiwkDm6tPMQeA== "@reach/router@^1.3.3": version "1.3.4" @@ -3439,9 +3439,9 @@ tslib "^2.1.0" "@testing-library/dom@*": - version "7.29.6" - resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-7.29.6.tgz#eb37844fb431186db7960a7ff6749ea65a19617c" - integrity sha512-vzTsAXa439ptdvav/4lsKRcGpAQX7b6wBIqia7+iNzqGJ5zjswApxA6jDAsexrc6ue9krWcbh8o+LYkBXW+GCQ== + version "7.30.0" + resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-7.30.0.tgz#53697851f7708a1448cc30b74a2ea056dd709cd6" + integrity sha512-v4GzWtltaiDE0yRikLlcLAfEiiK8+ptu6OuuIebm9GdC2XlZTNDPGEfM2UkEtnH7hr9TRq2sivT5EA9P1Oy7bw== dependencies: "@babel/code-frame" "^7.10.4" "@babel/runtime" "^7.12.5" @@ -3523,9 +3523,9 @@ integrity sha512-TbH79tcyi9FHwbyboOKeRachRq63mSuWYXOflsNO9ZyE5ClQ/JaozNKl+aWUq87qPNsXasXxi2AbgfwIJ+8GQw== "@types/cheerio@^0.22.22": - version "0.22.24" - resolved "https://registry.yarnpkg.com/@types/cheerio/-/cheerio-0.22.24.tgz#fcee47074aa221ac0f31ede0c72c0800bf3bf0aa" - integrity sha512-iKXt/cwltGvN06Dd6zwQG1U35edPwId9lmcSeYfcxSNvvNg4vysnFB+iBQNjj06tSVV7MBj0GWMQ7dwb4Z+p8Q== + version "0.22.25" + resolved "https://registry.yarnpkg.com/@types/cheerio/-/cheerio-0.22.25.tgz#2f77c99922a3459373a873d55caaa049ead26fa0" + integrity sha512-Y2kmbk74dSGRI1bBmo67bowDoVxNm9cs+IPZznsFPRuBN6ToK2RCATZipOJsgO0Unbtiy01o0hP2SS+MKdUNvQ== dependencies: "@types/node" "*" @@ -3538,9 +3538,9 @@ "@types/estree" "*" "@types/eslint@*": - version "7.2.6" - resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-7.2.6.tgz#5e9aff555a975596c03a98b59ecd103decc70c3c" - integrity sha512-I+1sYH+NPQ3/tVqCeUSBwTE/0heyvtXqpIopUUArlBm0Kpocb8FbMa3AZ/ASKIFpN3rnEx932TTXDbt9OXsNDw== + version "7.2.7" + resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-7.2.7.tgz#f7ef1cf0dceab0ae6f9a976a0a9af14ab1baca26" + integrity sha512-EHXbc1z2GoQRqHaAT7+grxlTJ3WE2YNeD6jlpPoRc83cCoThRY+NUWjCUZaYmk51OICkPXn2hhphcWcWXgNW0Q== dependencies: "@types/estree" "*" "@types/json-schema" "*" @@ -3683,9 +3683,9 @@ form-data "^3.0.0" "@types/node@*", "@types/node@>= 8": - version "14.14.31" - resolved "https://registry.yarnpkg.com/@types/node/-/node-14.14.31.tgz#72286bd33d137aa0d152d47ec7c1762563d34055" - integrity sha512-vFHy/ezP5qI0rFgJ7aQnjDXwAMrG0KqqIH7tQG5PPv3BWBayOPIQNBjVc/P6hhdZfMx51REc6tfDNXHUio893g== + version "14.14.32" + resolved "https://registry.yarnpkg.com/@types/node/-/node-14.14.32.tgz#90c5c4a8d72bbbfe53033f122341343249183448" + integrity sha512-/Ctrftx/zp4m8JOujM5ZhwzlWLx22nbQJiVqz8/zE15gOeEW+uly3FSX4fGFpcfEvFzXcMCJwq9lGVWgyARXhg== "@types/normalize-package-data@^2.4.0": version "2.4.0" @@ -3723,9 +3723,9 @@ integrity sha512-1HcDas8SEj4z1Wc696tH56G8OlRaH/sqZOynNNB+HF0WOeXPaxTtbYzJY2oEfiUxjSKjhCKr+MvR7dCHcEelug== "@types/qs@^6.9.0": - version "6.9.5" - resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.5.tgz#434711bdd49eb5ee69d90c1d67c354a9a8ecb18b" - integrity sha512-/JHkVHtx/REVG0VVToGRGH2+23hsYLHdyG+GrvoUGlGAd0ErauXDyvHtRI/7H7mzLm+tBCKA7pfcpkQ1lf58iQ== + version "6.9.6" + resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.6.tgz#df9c3c8b31a247ec315e6996566be3171df4b3b1" + integrity sha512-0/HnwIfW4ki2D8L8c9GVcG5I72s9jP5GSLVF0VIXDW00kmIpA6O33G7a8n59Tmh7Nz0WUC3rSb7PTY/sdW2JzA== "@types/reach__router@^1.3.7": version "1.3.7" @@ -3743,9 +3743,9 @@ "@types/reactcss" "*" "@types/react-dom@*": - version "17.0.1" - resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-17.0.1.tgz#d92d77d020bfb083e07cc8e0ac9f933599a4d56a" - integrity sha512-yIVyopxQb8IDZ7SOHeTovurFq+fXiPICa+GV3gp0Xedsl+MwQlMLKmvrnEjFbQxjliH5YVAEWFh975eVNmKj7Q== + version "17.0.2" + resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-17.0.2.tgz#35654cf6c49ae162d5bc90843d5437dc38008d43" + integrity sha512-Icd9KEgdnFfJs39KyRyr0jQ7EKhq8U6CcHRMGAS45fp5qgUvxL3ujUCfWFttUK2UErqZNj97t9gsVPNAqcwoCg== dependencies: "@types/react" "*" @@ -3764,11 +3764,12 @@ "@types/react" "*" "@types/react@*": - version "17.0.2" - resolved "https://registry.yarnpkg.com/@types/react/-/react-17.0.2.tgz#3de24c4efef902dd9795a49c75f760cbe4f7a5a8" - integrity sha512-Xt40xQsrkdvjn1EyWe1Bc0dJLcil/9x2vAuW7ya+PuQip4UYUaXyhzWmAbwRsdMgwOFHpfp7/FFZebDU6Y8VHA== + version "17.0.3" + resolved "https://registry.yarnpkg.com/@types/react/-/react-17.0.3.tgz#ba6e215368501ac3826951eef2904574c262cc79" + integrity sha512-wYOUxIgs2HZZ0ACNiIayItyluADNbONl7kt8lkLjVK8IitMH5QMyAh75Fwhmo37r1m7L2JaFj03sIfxBVDvRAg== dependencies: "@types/prop-types" "*" + "@types/scheduler" "*" csstype "^3.0.2" "@types/reactcss@*": @@ -3792,6 +3793,11 @@ dependencies: "@types/node" "*" +"@types/scheduler@*": + version "0.16.1" + resolved "https://registry.yarnpkg.com/@types/scheduler/-/scheduler-0.16.1.tgz#18845205e86ff0038517aab7a18a62a6b9f71275" + integrity sha512-EaCxbanVeyxDRTQBkdLb3Bvl/HK7PBK6UJjsSixB0iHKoWxE5uu2Q/DgtpOhPIojN0Zl1whvOd7PoHs2P0s5eA== + "@types/source-list-map@*": version "0.1.2" resolved "https://registry.yarnpkg.com/@types/source-list-map/-/source-list-map-0.1.2.tgz#0078836063ffaf17412349bba364087e0ac02ec9" @@ -3831,9 +3837,9 @@ pretty-format "^25.1.0" "@types/uglify-js@*": - version "3.12.0" - resolved "https://registry.yarnpkg.com/@types/uglify-js/-/uglify-js-3.12.0.tgz#2bb061c269441620d46b946350c8f16d52ef37c5" - integrity sha512-sYAF+CF9XZ5cvEBkI7RtrG9g2GtMBkviTnBxYYyq+8BWvO4QtXfwwR6a2LFwCi4evMKZfpv6U43ViYvv17Wz3Q== + version "3.13.0" + resolved "https://registry.yarnpkg.com/@types/uglify-js/-/uglify-js-3.13.0.tgz#1cad8df1fb0b143c5aba08de5712ea9d1ff71124" + integrity sha512-EGkrJD5Uy+Pg0NUR8uA4bJ5WMfljyad0G+784vLCNUkD+QwOJXUbBYExXfVGf7YtyzdQp3L/XMYcliB987kL5Q== dependencies: source-map "^0.6.1" @@ -5786,9 +5792,9 @@ caniuse-api@^3.0.0: lodash.uniq "^4.5.0" caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001109, caniuse-lite@^1.0.30001125, caniuse-lite@^1.0.30001181: - version "1.0.30001196" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001196.tgz#00518a2044b1abf3e0df31fadbe5ed90b63f4e64" - integrity sha512-CPvObjD3ovWrNBaXlAIGWmg2gQQuJ5YhuciUOjPRox6hIQttu8O+b51dx6VIpIY9ESd2d0Vac1RKpICdG4rGUg== + version "1.0.30001197" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001197.tgz#47ad15b977d2f32b3ec2fe2b087e0c50443771db" + integrity sha512-8aE+sqBqtXz4G8g35Eg/XEaFr2N7rd/VQ6eABGBmNtcB8cN6qNJhMi6oSFy4UWWZgqgL3filHT8Nha4meu3tsw== capture-exit@^2.0.0: version "2.0.0" @@ -7552,9 +7558,9 @@ ejs@^3.1.2: jake "^10.6.1" electron-to-chromium@^1.3.564, electron-to-chromium@^1.3.649: - version "1.3.682" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.682.tgz#f4b5c8d4479df96b61e508a721d6c32c1262ef23" - integrity sha512-zok2y37qR00U14uM6qBz/3iIjWHom2eRfC2S1StA0RslP7x34jX+j4mxv80t8OEOHLJPVG54ZPeaFxEI7gPrwg== + version "1.3.683" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.683.tgz#2c9ab53ff5275cf3dd49278af714d0f8975204f7" + integrity sha512-8mFfiAesXdEdE0DhkMKO7W9U6VU/9T3VTWwZ+4g84/YMP4kgwgFtQgUxuu7FUMcvSeKSNhFQNU+WZ68BQTLT5A== element-resize-detector@^1.2.1: version "1.2.2" @@ -7678,9 +7684,9 @@ entities@~2.1.0: integrity sha512-hCx1oky9PFrJ611mf0ifBLBRW8lUUVRlFolb5gWRfIELabBlbp9xZvrqZLZAs+NxFnbfQoeGd8wDkygjg7U85w== env-paths@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/env-paths/-/env-paths-2.2.0.tgz#cdca557dc009152917d6166e2febe1f039685e43" - integrity sha512-6u0VYSCo/OW6IoD5WCLLy9JUGARbamfSavcNXry/eu8aHVFei6CD3Sw+VGX5alea1i9pgPHW0mbu6Xj0uBh7gA== + version "2.2.1" + resolved "https://registry.yarnpkg.com/env-paths/-/env-paths-2.2.1.tgz#420399d416ce1fbe9bc0a07c62fa68d67fd0f8f2" + integrity sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A== envinfo@^7.3.1, envinfo@^7.7.3: version "7.7.4" @@ -8941,9 +8947,9 @@ glob-parent@^3.1.0: path-dirname "^1.0.0" glob-parent@^5.0.0, glob-parent@^5.1.0, glob-parent@^5.1.1, glob-parent@~5.1.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.1.tgz#b6c1ef417c4e5663ea498f1c45afac6916bbc229" - integrity sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ== + version "5.1.2" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" + integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== dependencies: is-glob "^4.0.1" @@ -9556,9 +9562,9 @@ htmlparser2@^5.0: entities "^2.0.0" htmlparser2@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-6.0.0.tgz#c2da005030390908ca4c91e5629e418e0665ac01" - integrity sha512-numTQtDZMoh78zJpaNdJ9MXb2cv5G3jwUoe3dMQODubZvLoGvTE/Ofp6sHvH8OGKcN/8A47pGLi/k58xHP/Tfw== + version "6.0.1" + resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-6.0.1.tgz#422521231ef6d42e56bd411da8ba40aa36e91446" + integrity sha512-GDKPd+vk4jvSuvCbyuzx/unmXkk090Azec7LovXP8as1Hn8q9p3hbjmDGbUqqhknw0ajwit6LiiWqfiTUPMK7w== dependencies: domelementtype "^2.0.1" domhandler "^4.0.0" @@ -14326,9 +14332,9 @@ react-custom-scrollbars@^4.2.1: raf "^3.1.0" react-dev-utils@^11.0.3: - version "11.0.3" - resolved "https://registry.yarnpkg.com/react-dev-utils/-/react-dev-utils-11.0.3.tgz#b61ed499c7d74f447d4faddcc547e5e671e97c08" - integrity sha512-4lEA5gF4OHrcJLMUV1t+4XbNDiJbsAWCH5Z2uqlTqW6dD7Cf5nEASkeXrCI/Mz83sI2o527oBIFKVMXtRf1Vtg== + version "11.0.4" + resolved "https://registry.yarnpkg.com/react-dev-utils/-/react-dev-utils-11.0.4.tgz#a7ccb60257a1ca2e0efe7a83e38e6700d17aa37a" + integrity sha512-dx0LvIGHcOPtKbeiSUM4jqpBl3TcY7CDjZdfOIcKeznE7BWr9dg0iPG90G5yfVQ+p/rGNMXdbfStvzQZEVEi4A== dependencies: "@babel/code-frame" "7.10.4" address "1.1.2" @@ -14484,9 +14490,9 @@ react-hotkeys@2.0.0: prop-types "^15.6.1" react-i18next@^11.7.3, react-i18next@^11.8.8: - version "11.8.8" - resolved "https://registry.yarnpkg.com/react-i18next/-/react-i18next-11.8.8.tgz#23d34518c784f2ada7cec41cfe439ac4ae51875c" - integrity sha512-Z8Daifh+FRpcQsCp48mWQViYSlojv0WiL2bf6e9DOzpfVMDaTT6qsYRbHCjLEeDeEioxoaWHMiWu2JPTW3Ni4w== + version "11.8.9" + resolved "https://registry.yarnpkg.com/react-i18next/-/react-i18next-11.8.9.tgz#188039708f99a6114b4437f0e620bf99a6c3c7dd" + integrity sha512-HVW4/KtBvXcnzkYeS32IqdGBJJ1fksvqVDnnspsyruO99fhHQaAw1vTSrRpcNE5D8vrOu7B9c6sawfmQJ6OWRg== dependencies: "@babel/runtime" "^7.13.6" html-parse-stringify2 "^2.0.1" @@ -14748,9 +14754,9 @@ react-viewer@^3.2.2: classnames "^2.2.5" react-virtualized-auto-sizer@^1.0.2, react-virtualized-auto-sizer@^1.0.3: - version "1.0.4" - resolved "https://registry.yarnpkg.com/react-virtualized-auto-sizer/-/react-virtualized-auto-sizer-1.0.4.tgz#2b83adb5ecdee8dcb33784e96ee0074eb5369665" - integrity sha512-fdrY0ZX4Ywv0IIYPY/grQXcVQ44OLOsftl2u81coKe2Ga1wT3ps4JXaeu1JdlfjQxDI5BVsWjZQbpzmjmtI7Qw== + version "1.0.5" + resolved "https://registry.yarnpkg.com/react-virtualized-auto-sizer/-/react-virtualized-auto-sizer-1.0.5.tgz#9eeeb8302022de56fbd7a860b08513120ce36509" + integrity sha512-kivjYVWX15TX2IUrm8F1jaCEX8EXrpy3DD+u41WGqJ1ZqbljWpiwscV+VxOM1l7sSIM1jwi2LADjhhAJkJ9dxA== react-window-infinite-loader@^1.0.5: version "1.0.7" @@ -15546,9 +15552,9 @@ rollup@^1.32.1: acorn "^7.1.0" rollup@^2.25.0: - version "2.40.0" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.40.0.tgz#efc218eaede7ab590954df50f96195188999c304" - integrity sha512-WiOGAPbXoHu+TOz6hyYUxIksOwsY/21TRWoO593jgYt8mvYafYqQl+axaA8y1z2HFazNUUrsMSjahV2A6/2R9A== + version "2.41.0" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.41.0.tgz#b2a398bbabbf227738dedaef099e494aed468982" + integrity sha512-Gk76XHTggulWPH95q8V62bw6uqDH6UGvbD6LOa3QUyhuMF3eOuaeDHR7SLm1T9faitkpNrqzUAVYx47klcMnlA== optionalDependencies: fsevents "~2.3.1" @@ -17438,9 +17444,9 @@ unist-util-generated@^1.0.0: integrity sha512-cln2Mm1/CZzN5ttGK7vkoGw+RZ8VcUH6BtGbq98DDtRGquAAOXig1mrBQYelOwMXYS8rK+vZDyyojSjp7JX+Lg== unist-util-is@^4.0.0: - version "4.0.4" - resolved "https://registry.yarnpkg.com/unist-util-is/-/unist-util-is-4.0.4.tgz#3e9e8de6af2eb0039a59f50c9b3e99698a924f50" - integrity sha512-3dF39j/u423v4BBQrk1AQ2Ve1FxY5W3JKwXxVFzBODQ6WEvccguhgp802qQLKSnxPODE6WuRZtV+ohlUg4meBA== + version "4.1.0" + resolved "https://registry.yarnpkg.com/unist-util-is/-/unist-util-is-4.1.0.tgz#976e5f462a7a5de73d94b706bac1b90671b57797" + integrity sha512-ZOQSsnce92GrxSqlnEEseX0gi7GH9zTJZ0p9dtu87WRb/37mMPO2Ilx1s/t9vBHrFhbgweUwb+t7cIn5dxPhZg== unist-util-position@^3.0.0: version "3.1.0" From 751eb1d4b60f926821015aa9a8000b2b0e2499c9 Mon Sep 17 00:00:00 2001 From: Vladislav Makhov Date: Tue, 9 Mar 2021 14:53:33 +0300 Subject: [PATCH 2/2] web: people: refactoring --- .../pages/Home/Section/Body/ContextMenu.js | 215 ------------------ .../pages/Home/Section/Body/SimpleUserRow.js | 25 +- 2 files changed, 5 insertions(+), 235 deletions(-) delete mode 100644 products/ASC.People/Client/src/components/pages/Home/Section/Body/ContextMenu.js diff --git a/products/ASC.People/Client/src/components/pages/Home/Section/Body/ContextMenu.js b/products/ASC.People/Client/src/components/pages/Home/Section/Body/ContextMenu.js deleted file mode 100644 index 4155563d67..0000000000 --- a/products/ASC.People/Client/src/components/pages/Home/Section/Body/ContextMenu.js +++ /dev/null @@ -1,215 +0,0 @@ -import React from "react"; -import history from "@appserver/common/history"; -import { Trans } from "react-i18next"; - -import { resendUserInvites } from "@appserver/common/api/people"; -import { EmployeeStatus } from "@appserver/common/constants"; -import config from "../../../../../../package.json"; -import toastr from "@appserver/common/components/Toast/toastr"; -import PeopleStore from "../../../../../store/PeopleStore"; -import { observe } from "mobx"; - -const peopleStore = new PeopleStore(); - -const onEmailSentClick = (email) => () => window.open("mailto:" + email); - -const onSendMessageClick = (mobilePhone) => () => - window.open(`sms:${mobilePhone}`); - -const onEditClick = (userName) => () => - history.push(`${config.homepage}/edit/${userName}`); - -const toggleChangePasswordDialog = (email) => { - return () => { - peopleStore.dialogStore.setDialogData({ - email, - }); - peopleStore.dialogStore.setChangePasswordDialogVisible(true); - console.log( - "peopleStore.dialogStore.changePassword: ", - peopleStore.dialogStore.changePassword - ); - }; -}; - -const toggleChangeEmailDialog = (email, id) => { - return () => { - peopleStore.dialogStore.setDialogData({ - email, - id, - }); - }; -}; - -const toggleDeleteSelfProfileDialog = (email) => { - return () => { - peopleStore.dialogStore.closeDialogs(); - peopleStore.dialogStore.setDialogData({ - email, - }); - peopleStore.dialogStore.setDeleteSelfProfileDialogVisible(true); - }; -}; - -const toggleDeleteProfileEverDialog = (id, displayName, userName) => { - return () => { - peopleStore.dialogStore.closeDialogs(); - peopleStore.dialogStore.setDialogData({ - id, - displayName, - userName, - }); - peopleStore.dialogStore.setDeleteProfileDialogVisible(true); - }; -}; - -const onDisableClick = (id) => { - return () => { - //onLoading(true); - - peopleStore.usersStore.updateUserStatus( - EmployeeStatus.Disabled, - [id], - true - ); - toastr.success("SuccessChangeUserStatus"); - // toastr.success(t("SuccessChangeUserStatus")); - // .catch((error) => toastr.error(error)); - //.finally(() => onLoading(false)); - }; -}; - -const onEnableClick = (id) => { - return () => { - //onLoading(true); - peopleStore.usersStore - .updateUserStatus(EmployeeStatus.Active, [id], true) - .then(() => toastr.success(t("SuccessChangeUserStatus"))) - .catch((error) => toastr.error(error)); - //.finally(() => onLoading(false)); - }; -}; - -const onReassignDataClick = (userName) => () => - history.push(`${homepage}/reassign/${userName}`); - -const onDeletePersonalDataClick = () => - toastr.success("Context action: Delete personal data"); //TODO: Implement and add translation - -const onInviteAgainClick = (id, email) => { - return () => { - //onLoading(true); - resendUserInvites([id]) - .then(() => - toastr.success( - - The email activation instructions have been sent to the - {{ email: email }} email address - - ) - ) - .catch((error) => toastr.error(error)); - //.finally(() => onLoading(false)); - }; -}; - -export const getUserContextOptions = (user, t) => { - const { options, email, id, mobilePhone, userName, displayName } = user; - return options.map((option) => { - switch (option) { - case "send-email": - return { - key: option, - label: t("LblSendEmail"), - "data-id": id, - onClick: onEmailSentClick(email), - }; - case "send-message": - return { - key: option, - label: t("LblSendMessage"), - "data-id": id, - onClick: onSendMessageClick(mobilePhone), - }; - case "separator": - return { key: option, isSeparator: true }; - case "edit": - return { - key: option, - label: t("EditButton"), - "data-id": id, - onClick: onEditClick(userName), - }; - case "change-password": - return { - key: option, - label: t("PasswordChangeButton"), - "data-id": id, - onClick: toggleChangePasswordDialog(email), - }; - case "change-email": - return { - key: option, - label: t("EmailChangeButton"), - "data-id": id, - onClick: toggleChangeEmailDialog(email), - }; - case "delete-self-profile": - return { - key: option, - label: t("DeleteSelfProfile"), - "data-id": id, - onClick: toggleDeleteSelfProfileDialog(email), - }; - case "disable": - return { - key: option, - label: t("DisableUserButton"), - "data-id": id, - onClick: onDisableClick(id), - }; - case "enable": - return { - key: option, - label: t("EnableUserButton"), - "data-id": id, - onClick: onEnableClick(id), - }; - case "reassign-data": - return { - key: option, - label: t("ReassignData"), - "data-id": id, - onClick: onReassignDataClick(userName), - }; - case "delete-personal-data": - return { - key: option, - label: t("RemoveData"), - "data-id": id, - onClick: onDeletePersonalDataClick, - }; - case "delete-profile": - return { - key: option, - label: t("DeleteSelfProfile"), - "data-id": id, - onClick: toggleDeleteProfileEverDialog(id, displayName, userName), - }; - case "invite-again": - return { - key: option, - label: t("LblInviteAgain"), - "data-id": id, - onClick: onInviteAgainClick(id, email), - }; - default: - break; - } - - return undefined; - }); -}; diff --git a/products/ASC.People/Client/src/components/pages/Home/Section/Body/SimpleUserRow.js b/products/ASC.People/Client/src/components/pages/Home/Section/Body/SimpleUserRow.js index 0df30d4054..96ad5af684 100644 --- a/products/ASC.People/Client/src/components/pages/Home/Section/Body/SimpleUserRow.js +++ b/products/ASC.People/Client/src/components/pages/Home/Section/Body/SimpleUserRow.js @@ -8,7 +8,6 @@ import toastr from "studio/toastr"; import { EmployeeStatus } from "@appserver/common/constants"; import { resendUserInvites } from "@appserver/common/api/people"; //TODO: Move to store action import { withRouter } from "react-router"; -// import { getUserContextOptions } from "./ContextMenu"; const SimpleUserRow = ({ person, @@ -27,7 +26,6 @@ const SimpleUserRow = ({ setDialogData, closeDialogs, updateUserStatus, - contextMenu, history, }) => { const { t } = useTranslation("Home"); @@ -46,13 +44,8 @@ const SimpleUserRow = ({ currentUserId, } = person; - const onContentRowSelect = (checked, user) => { - if (checked) { - selectUser(user); - } else { - deselectUser(user); - } - }; + const onContentRowSelect = (checked, user) => + checked ? selectUser(user) : deselectUser(user); const onEmailSentClick = () => { window.open("mailto:" + email); @@ -148,7 +141,7 @@ const SimpleUserRow = ({ }; const getUserContextOptions = (options, id) => { - return options.map((option) => { + const contextMenu = options.map((option) => { switch (option) { case "send-email": return { @@ -242,6 +235,8 @@ const SimpleUserRow = ({ return undefined; }); + + return contextMenu; }; const showContextMenu = options && options.length > 0; @@ -255,7 +250,6 @@ const SimpleUserRow = ({ (isAdmin && showContextMenu) || (showContextMenu && id === currentUserId) ? { contextOptions: getUserContextOptions(options, id), - // contextOptions: contextMenu, } : {}; @@ -284,10 +278,7 @@ const SimpleUserRow = ({ }; export default inject(({ auth, peopleStore }, { person }) => { - // const { t } = useTranslation("Home"); - return { - // contextMenu: getUserContextOptions(person, t), homepage: auth.settingsStore.homepage, isAdmin: auth.isAdmin, currentUserId: auth.userStore.user.id, @@ -297,22 +288,16 @@ export default inject(({ auth, peopleStore }, { person }) => { selectUser: peopleStore.selectionStore.selectUser, deselectUser: peopleStore.selectionStore.deselectUser, selectGroup: peopleStore.selectedGroupStore.selectGroup, - setChangeEmailDialogVisible: peopleStore.dialogStore.setChangeEmailDialogVisible, - setChangePasswordDialogVisible: peopleStore.dialogStore.setChangePasswordDialogVisible, - setDeleteSelfProfileDialogVisible: peopleStore.dialogStore.setDeleteSelfProfileDialogVisible, - setDeleteProfileDialogVisible: peopleStore.dialogStore.setDeleteProfileDialogVisible, - setDialogData: peopleStore.dialogStore.setDialogData, closeDialogs: peopleStore.dialogStore.closeDialogs, - updateUserStatus: peopleStore.usersStore.updateUserStatus, }; })(withRouter(observer(SimpleUserRow)));