@bigbinary/neeto-molecules 3.7.31 → 3.7.33
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/dist/Chevron-DDPJH8ie.js +222 -0
- package/dist/{Chevron-DWt0ncDv.js.map → Chevron-DDPJH8ie.js.map} +1 -1
- package/dist/ConfigurePageSidebar.js +1 -1
- package/dist/DynamicVariables.js +5 -2
- package/dist/DynamicVariables.js.map +1 -1
- package/dist/FloatingActionMenu.js +5 -5
- package/dist/FloatingActionMenu.js.map +1 -1
- package/dist/NeetoWidget.js +13 -13
- package/dist/NeetoWidget.js.map +1 -1
- package/dist/Sidebar.js +1 -1
- package/dist/cjs/{Chevron-DpYyQWkK.js → Chevron-D9ITVEQr.js} +2 -2
- package/dist/cjs/{Chevron-DpYyQWkK.js.map → Chevron-D9ITVEQr.js.map} +1 -1
- package/dist/cjs/ConfigurePageSidebar.js +1 -1
- package/dist/cjs/DynamicVariables.js +4 -1
- package/dist/cjs/DynamicVariables.js.map +1 -1
- package/dist/cjs/FloatingActionMenu.js +5 -5
- package/dist/cjs/FloatingActionMenu.js.map +1 -1
- package/dist/cjs/NeetoWidget.js +13 -13
- package/dist/cjs/NeetoWidget.js.map +1 -1
- package/dist/cjs/Sidebar.js +1 -1
- package/package.json +1 -1
- package/src/translations/en.json +2 -2
- package/types/DynamicVariables.d.ts +3 -1
- package/types/FloatingActionMenu.d.ts +3 -3
- package/types/NeetoWidget.d.ts +1 -1
- package/dist/Chevron-DWt0ncDv.js +0 -222
package/dist/Sidebar.js
CHANGED
|
@@ -8,7 +8,7 @@ import Button from '@bigbinary/neetoui/Button';
|
|
|
8
8
|
import { not, is, findLast } from 'ramda';
|
|
9
9
|
import { useTranslation } from 'react-i18next';
|
|
10
10
|
import { Link, useLocation, useHistory } from 'react-router-dom';
|
|
11
|
-
import { f as filterByPermissions, a as CheckPointNavLinks, _ as _Items, b as SELECTED_NAV_LINK_ROUTE_STORAGE_KEY, g as getSidebarStateLocalStorageKey, S as SelectedLink, C as Chevron, c as findCurrentConfigureNavLink } from './Chevron-
|
|
11
|
+
import { f as filterByPermissions, a as CheckPointNavLinks, _ as _Items, b as SELECTED_NAV_LINK_ROUTE_STORAGE_KEY, g as getSidebarStateLocalStorageKey, S as SelectedLink, C as Chevron, c as findCurrentConfigureNavLink } from './Chevron-DDPJH8ie.js';
|
|
12
12
|
import useFetchNeetoApps from '@bigbinary/neeto-commons-frontend/react-utils/useFetchNeetoApps';
|
|
13
13
|
import Neeto from '@bigbinary/neeto-icons/typeface-logos/Neeto';
|
|
14
14
|
import * as AppIcons from '@bigbinary/neeto-icons/typeface-logos';
|
|
@@ -203,7 +203,7 @@ var SelectedLink = function SelectedLink(_ref) {
|
|
|
203
203
|
});
|
|
204
204
|
};
|
|
205
205
|
|
|
206
|
-
var css = ":root{--neeto-molecules-sidebar-width:240px;--neeto-molecules-sidebar-wrapper-z-index:99997;--neeto-molecules-sidebar-z-index:99998;--neeto-chat-primary:136,134,255;--neeto-wireframe-primary:106,103,232;--neeto-site-primary:129,118,255;--neeto-desk-primary:253,148,55;--neeto-planner-primary:82,169,198;--neeto-replay-primary:32,199,189;--neeto-course-primary:140,214,114;--neeto-ci-primary:255,133,184;--neeto-invoice-primary:70,160,211;--neeto-quiz-primary:254,99,99;--neeto-runner-primary:75,71,255;--neeto-form-primary:254,128,114;--neeto-crm-primary:96,154,240;--neeto-changelog-primary:255,135,135;--neeto-deploy-primary:20,209,164;--neeto-kb-primary:101,205,161;--neeto-cal-primary:238,77,95;--neeto-invisible-primary:121,157,250;--neeto-testify-primary:255,158,69;--neeto-monitor-primary:70,181,197;--neeto-git-primary:255,78,110}@media screen and (min-width:1024px){:root{--neeto-molecules-sidebar-width:240px}}.neeto-molecules-sidebar__wrapper{display:flex;max-width:240px;max-width:var(--neeto-molecules-sidebar-width);position:relative;transition:all .15s;width:240px;width:var(--neeto-molecules-sidebar-width)}@media screen and (max-width:768px){.neeto-molecules-sidebar__wrapper{height:100%;left:0;max-width:100%;position:fixed;top:0;transition:none;width:100%;z-index:99997;z-index:var(--neeto-molecules-sidebar-wrapper-z-index)}.neeto-molecules-sidebar__wrapper .neeto-molecules-sidebar{left:0;max-width:240px;max-width:var(--neeto-molecules-sidebar-width);position:fixed;top:0;transition:none;width:240px;width:var(--neeto-molecules-sidebar-width)}}.neeto-molecules-sidebar__wrapper__configure-page .neeto-molecules-sidebar__toggler{right:20px}@media screen and (max-width:768px){.neeto-molecules-sidebar__wrapper__configure-page .neeto-molecules-sidebar__toggler{right:auto}}.neeto-molecules-sidebar__wrapper--collapsed{max-width:0;width:0}.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar__toggler{right:-36px;transform:scale(-1)}@media screen and (max-width:768px){.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar__toggler{left:8px;right:auto}.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar{left:-240px;left:calc(var(--neeto-molecules-sidebar-width)*-1)}.neeto-molecules-sidebar__wrapper__configure-page.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar__toggler{top:109px}}.neeto-molecules-sidebar{background-color:rgb(var(--neeto-ui-white));border-right:1px solid rgb(var(--neeto-ui-gray-200));height:100vh;padding:24px 0;width:100%;z-index:99998;z-index:var(--neeto-molecules-sidebar-z-index)}.neeto-molecules-sidebar__no-shrinkable{max-width:240px;max-width:var(--neeto-molecules-sidebar-width);width:240px;width:var(--neeto-molecules-sidebar-width)}.neeto-molecules-sidebar__separator{margin:6px auto;width:100%}.neeto-molecules-sidebar::-webkit-scrollbar{height:0;width:0}.neeto-molecules-sidebar::-webkit-scrollbar-thumb{background:rgb(var(--neeto-ui-gray-300));border-radius:50px}.neeto-molecules-sidebar::-webkit-scrollbar-track{background:\"transparent\"}.neeto-molecules-sidebar__toggler{color:rgb(var(--neeto-ui-primary-500))!important;position:absolute;right:8px;top:8px;z-index:99998;z-index:var(--neeto-molecules-sidebar-z-index)}@media screen and (max-width:768px){.neeto-molecules-sidebar__toggler{left:202px;left:calc(var(--neeto-molecules-sidebar-width) - 38px);right:auto;transition:none}}.neeto-molecules-sidebar__configure-page{border-right:1px solid rgb(var(--neeto-ui-gray-200));height:auto}@media screen and (max-width:768px){.neeto-molecules-sidebar__configure-page{height:100%}}.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__links{height:calc(100vh - 136px)!important}@media screen and (max-width:768px){.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__links{height:calc(100vh - 80px)!important}}.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__toggler{display:none}.neeto-molecules-sidebar__header{margin:14px 0 28px;padding:0 24px}.neeto-molecules-sidebar__logo svg{height:36px;max-width:100%;width:auto}.neeto-molecules-sidebar__links{margin-bottom:40px}.neeto-molecules-sidebar__link{color:rgb(var(--neeto-ui-black));gap:10px;line-height:1.2;padding:12px 24px;position:relative;text-decoration:none!important;transition:color .3s,background-color .3s;width:100%}.neeto-molecules-sidebar__link-icon{flex-shrink:0}.neeto-molecules-sidebar__link-icon svg path{vector-effect:non-scaling-stroke}.neeto-molecules-sidebar__link-icon--rotate{transform:scale(-1)}.neeto-molecules-sidebar__link-icon--caret{opacity:0;transition:opacity .3s ease-in-out}.neeto-molecules-sidebar__link-label,.neeto-molecules-sidebar__link-sub-label{--neeto-ui-text-body2:15px;flex-grow:1;text-align:left}@media screen and (min-width:1536px){.neeto-molecules-sidebar__link-label,.neeto-molecules-sidebar__link-sub-label{--neeto-ui-text-body2:16px}}.neeto-molecules-sidebar__link:hover{background-color:rgb(var(--neeto-ui-gray-100));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link:focus,.neeto-molecules-sidebar__link:focus-visible,.neeto-molecules-sidebar__link[aria-expanded=true]{background-color:rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black));outline:none}.neeto-molecules-sidebar__link.active{background-color:rgb(var(--neeto-ui-accent-100));color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-semibold)}.neeto-molecules-sidebar__link.active .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link:focus .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link:focus-visible .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link:hover .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link[aria-expanded=true] .neeto-molecules-sidebar__link-icon--caret{opacity:1}.neeto-molecules-sidebar__link--button:focus{background-color:transparent}.neeto-molecules-sidebar__link--button:focus-visible{background-color:rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link--change-log{outline:none!important}.neeto-molecules-sidebar__sublink-wrapper{padding:4px 0}.neeto-molecules-sidebar__sublink{color:rgb(var(--neeto-ui-gray-700));cursor:pointer;gap:8px;margin-bottom:0;padding:8px 24px 8px 58px;text-decoration:none;transition:color .3s,background-color .3s}.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{--neeto-ui-text-body2:15px;opacity:.75}@media screen and (min-width:1536px){.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{--neeto-ui-text-body2:16px}}.neeto-molecules-sidebar__sublink:hover{color:rgb(var(--neeto-ui-black));text-decoration:none}.neeto-molecules-sidebar__sublink:hover .neeto-molecules-sidebar__link-sub-count{opacity:1}.neeto-molecules-sidebar__sublink:focus,.neeto-molecules-sidebar__sublink:focus-visible{color:rgb(var(--neeto-ui-black));outline:none;text-decoration:none}.neeto-molecules-sidebar__sublink:focus .neeto-molecules-sidebar__link-sub-count,.neeto-molecules-sidebar__sublink:focus-visible .neeto-molecules-sidebar__link-sub-count{opacity:1}.neeto-molecules-sidebar__sublink.active,.neeto-molecules-sidebar__sublink:active{color:rgb(var(--neeto-ui-accent-800));font-weight:500;text-decoration:none}.neeto-molecules-sidebar__sublink.active .neeto-molecules-sidebar__link-sub-count,.neeto-molecules-sidebar__sublink:active .neeto-molecules-sidebar__link-sub-count{opacity:1}.neeto-molecules-sidebar__footer{margin-top:auto}.sidebar-featured-tooltip__content{border-radius:8px!important;box-shadow:var(--neeto-ui-shadow-sm)!important}.sidebar-featured-tooltip__content .tippy-content{padding:0}.sidebar-featured-tooltip{padding:12px;width:150px}.sidebar-featured-tooltip__icon-wrap{background-color:rgb(var(--neeto-ui-gray-100));border-radius:8px;height:40px;margin-bottom:8px;margin-left:auto;margin-right:auto;width:40px}.sidebar-featured-tooltip__title{margin-bottom:4px}.neeto-molecules-help-popup-wrapper,.neeto-molecules-product-switcher-popup-wrapper,.neeto-molecules-profile-popup-wrapper{border:1px solid rgb(var(--neeto-ui-gray-400));border-radius:var(--neeto-ui-rounded)!important;min-width:240px}.neeto-molecules-help-popup-wrapper .tippy-content,.neeto-molecules-product-switcher-popup-wrapper .tippy-content,.neeto-molecules-profile-popup-wrapper .tippy-content{padding:0}.neeto-molecules-help-popup-wrapper .tippy-svg-arrow,.neeto-molecules-product-switcher-popup-wrapper .tippy-svg-arrow,.neeto-molecules-profile-popup-wrapper .tippy-svg-arrow{display:none!important}.neeto-molecules-profile-popup__top-section{border-top-left-radius:var(--neeto-ui-rounded);border-top-right-radius:var(--neeto-ui-rounded)}.neeto-molecules-profile-sublist{border-top:1px solid rgb(var(--neeto-ui-gray-400))}.neeto-molecules-help-sublist,.neeto-molecules-profile-sublist{list-style:none;margin:0;padding:4px 0}.neeto-molecules-help-sublist__item,.neeto-molecules-profile-sublist__item{width:100%}.neeto-molecules-help-sublist__item-btn,.neeto-molecules-profile-sublist__item-btn{border-radius:0;justify-content:flex-end!important;min-height:40px;text-align:left}.neeto-molecules-help-sublist__item-btn.active,.neeto-molecules-profile-sublist__item-btn.active{background-color:rgb(var(--neeto-ui-gray-800));color:rgb(var(--neeto-ui-white))}.neeto-molecules-help-sublist__item-btn-icon svg path,.neeto-molecules-profile-sublist__item-btn-icon svg path{vector-effect:non-scaling-stroke}.neeto-molecules-help-sublist__item-btn span,.neeto-molecules-profile-sublist__item-btn span{align-items:center;display:flex;gap:8px}.neeto-molecules-sidebar__link-icon{position:relative}.neeto-molecules-sidebar__notif-count{position:absolute;right:-6px;top:-6px;z-index:1}.neeto-molecules-help-sublist__item-btn-count,.neeto-molecules-sidebar__notif-count{align-items:center;background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded-full);color:rgb(var(--neeto-ui-white));display:inline-flex;flex-shrink:0;font-size:var(--neeto-ui-text-xxs);height:15px;justify-content:center;text-align:center;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:15px}.neeto-molecules-product-switcher-popup-wrapper{height:calc(100vh - 16px);margin-bottom:8px;min-width:calc(100vw - 176px);overflow-y:auto}@media screen and (max-width:768px){.neeto-molecules-product-switcher-popup-wrapper{width:calc(100vw - 185px)!important}}.neeto-molecules-sidebar__backdrop{background-color:rgba(var(--neeto-ui-black),.4);height:100%;left:0;position:absolute;top:0;width:100%}@media screen and (min-width:769px){.neeto-molecules-sidebar__backdrop{display:none;visibility:hidden}}.neeto-molecules-sidebar-segments-header{padding-left:58px}.neeto-molecules-sidebar-segment{margin-bottom:0!important;padding:4px 24px 4px 58px}.neeto-molecules-sidebar.neeto-molecules-sidebar--focus-mode{padding-top:0}.neeto-molecules-sidebar.neeto-molecules-sidebar--focus-mode .neeto-molecules-sidebar__header{padding-top:24px}.neeto-molecules-sidebar.neeto-molecules-sidebar--focus-mode .neeto-molecules-sidebar__links{display:flex;flex-direction:column;height:calc(100vh - 160px);margin-bottom:0}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper{flex-grow:1;margin:0 0 10px!important;min-height:0;overflow-y:auto;padding:0 0 10px!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink-wrapper{padding:0!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{border-radius:0}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link{--neeto-ui-text-body1:18px;background-color:rgb(var(--neeto-ui-gray-100));color:rgb(var(--neeto-ui-black));cursor:pointer;font-weight:var(--neeto-ui-font-semibold);gap:4px;padding:12px 4px;position:sticky;top:0;z-index:1}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link-label,.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link-sub-label{--neeto-ui-text-body2:15px}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink{color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-medium);margin-bottom:0;padding-bottom:10px;padding-top:10px}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink.active{font-weight:var(--neeto-ui-font-semibold)}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{border-radius:0;padding-left:32px}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink{cursor:pointer;line-height:1.2;padding:8px 12px 8px 24px;position:relative}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink:hover{background-color:rgb(var(--neeto-ui-gray-100))}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink.active{background-color:rgb(var(--neeto-ui-accent-100))!important;color:rgb(var(--neeto-ui-black))!important;font-weight:var(--neeto-ui-font-medium)}.neeto-molecules-sidebar__link-unread-count{align-items:center;background-color:rgb(var(--neeto-ui-accent-500));border-radius:var(--neeto-ui-rounded-full);color:rgb(var(--neeto-ui-white));display:flex;flex-shrink:0;font-size:var(--neeto-ui-text-xxs);height:16px;justify-content:center;min-width:16px;padding-left:4px;padding-right:4px;position:absolute;right:-4px;top:-4px;-webkit-user-select:none;-moz-user-select:none;user-select:none}.neeto-ui-theme--dark .neeto-molecules-sidebar__logo>path{fill:rgb(var(--neeto-ui-black))}";
|
|
206
|
+
var css = ":root{--neeto-molecules-sidebar-width:240px;--neeto-molecules-sidebar-wrapper-z-index:99997;--neeto-molecules-sidebar-z-index:99998;--neeto-chat-primary:136,134,255;--neeto-wireframe-primary:106,103,232;--neeto-site-primary:129,118,255;--neeto-desk-primary:253,148,55;--neeto-planner-primary:82,169,198;--neeto-replay-primary:32,199,189;--neeto-course-primary:140,214,114;--neeto-ci-primary:255,133,184;--neeto-invoice-primary:70,160,211;--neeto-quiz-primary:254,99,99;--neeto-runner-primary:75,71,255;--neeto-form-primary:254,128,114;--neeto-crm-primary:96,154,240;--neeto-engage-primary:255,135,135;--neeto-deploy-primary:20,209,164;--neeto-kb-primary:101,205,161;--neeto-cal-primary:238,77,95;--neeto-invisible-primary:121,157,250;--neeto-testify-primary:255,158,69;--neeto-monitor-primary:70,181,197;--neeto-git-primary:255,78,110}@media screen and (min-width:1024px){:root{--neeto-molecules-sidebar-width:240px}}.neeto-molecules-sidebar__wrapper{display:flex;max-width:240px;max-width:var(--neeto-molecules-sidebar-width);position:relative;transition:all .15s;width:240px;width:var(--neeto-molecules-sidebar-width)}@media screen and (max-width:768px){.neeto-molecules-sidebar__wrapper{height:100%;left:0;max-width:100%;position:fixed;top:0;transition:none;width:100%;z-index:99997;z-index:var(--neeto-molecules-sidebar-wrapper-z-index)}.neeto-molecules-sidebar__wrapper .neeto-molecules-sidebar{left:0;max-width:240px;max-width:var(--neeto-molecules-sidebar-width);position:fixed;top:0;transition:none;width:240px;width:var(--neeto-molecules-sidebar-width)}}.neeto-molecules-sidebar__wrapper__configure-page .neeto-molecules-sidebar__toggler{right:20px}@media screen and (max-width:768px){.neeto-molecules-sidebar__wrapper__configure-page .neeto-molecules-sidebar__toggler{right:auto}}.neeto-molecules-sidebar__wrapper--collapsed{max-width:0;width:0}.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar__toggler{right:-36px;transform:scale(-1)}@media screen and (max-width:768px){.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar__toggler{left:8px;right:auto}.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar{left:-240px;left:calc(var(--neeto-molecules-sidebar-width)*-1)}.neeto-molecules-sidebar__wrapper__configure-page.neeto-molecules-sidebar__wrapper--collapsed .neeto-molecules-sidebar__toggler{top:109px}}.neeto-molecules-sidebar{background-color:rgb(var(--neeto-ui-white));border-right:1px solid rgb(var(--neeto-ui-gray-200));height:100vh;padding:24px 0;width:100%;z-index:99998;z-index:var(--neeto-molecules-sidebar-z-index)}.neeto-molecules-sidebar__no-shrinkable{max-width:240px;max-width:var(--neeto-molecules-sidebar-width);width:240px;width:var(--neeto-molecules-sidebar-width)}.neeto-molecules-sidebar__separator{margin:6px auto;width:100%}.neeto-molecules-sidebar::-webkit-scrollbar{height:0;width:0}.neeto-molecules-sidebar::-webkit-scrollbar-thumb{background:rgb(var(--neeto-ui-gray-300));border-radius:50px}.neeto-molecules-sidebar::-webkit-scrollbar-track{background:\"transparent\"}.neeto-molecules-sidebar__toggler{color:rgb(var(--neeto-ui-primary-500))!important;position:absolute;right:8px;top:8px;z-index:99998;z-index:var(--neeto-molecules-sidebar-z-index)}@media screen and (max-width:768px){.neeto-molecules-sidebar__toggler{left:202px;left:calc(var(--neeto-molecules-sidebar-width) - 38px);right:auto;transition:none}}.neeto-molecules-sidebar__configure-page{border-right:1px solid rgb(var(--neeto-ui-gray-200));height:auto}@media screen and (max-width:768px){.neeto-molecules-sidebar__configure-page{height:100%}}.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__links{height:calc(100vh - 136px)!important}@media screen and (max-width:768px){.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__links{height:calc(100vh - 80px)!important}}.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__toggler{display:none}.neeto-molecules-sidebar__header{margin:14px 0 28px;padding:0 24px}.neeto-molecules-sidebar__logo svg{height:36px;max-width:100%;width:auto}.neeto-molecules-sidebar__links{margin-bottom:40px}.neeto-molecules-sidebar__link{color:rgb(var(--neeto-ui-black));gap:10px;line-height:1.2;padding:12px 24px;position:relative;text-decoration:none!important;transition:color .3s,background-color .3s;width:100%}.neeto-molecules-sidebar__link-icon{flex-shrink:0}.neeto-molecules-sidebar__link-icon svg path{vector-effect:non-scaling-stroke}.neeto-molecules-sidebar__link-icon--rotate{transform:scale(-1)}.neeto-molecules-sidebar__link-icon--caret{opacity:0;transition:opacity .3s ease-in-out}.neeto-molecules-sidebar__link-label,.neeto-molecules-sidebar__link-sub-label{--neeto-ui-text-body2:15px;flex-grow:1;text-align:left}@media screen and (min-width:1536px){.neeto-molecules-sidebar__link-label,.neeto-molecules-sidebar__link-sub-label{--neeto-ui-text-body2:16px}}.neeto-molecules-sidebar__link:hover{background-color:rgb(var(--neeto-ui-gray-100));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link:focus,.neeto-molecules-sidebar__link:focus-visible,.neeto-molecules-sidebar__link[aria-expanded=true]{background-color:rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black));outline:none}.neeto-molecules-sidebar__link.active{background-color:rgb(var(--neeto-ui-accent-100));color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-semibold)}.neeto-molecules-sidebar__link.active .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link:focus .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link:focus-visible .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link:hover .neeto-molecules-sidebar__link-icon--caret,.neeto-molecules-sidebar__link[aria-expanded=true] .neeto-molecules-sidebar__link-icon--caret{opacity:1}.neeto-molecules-sidebar__link--button:focus{background-color:transparent}.neeto-molecules-sidebar__link--button:focus-visible{background-color:rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link--change-log{outline:none!important}.neeto-molecules-sidebar__sublink-wrapper{padding:4px 0}.neeto-molecules-sidebar__sublink{color:rgb(var(--neeto-ui-gray-700));cursor:pointer;gap:8px;margin-bottom:0;padding:8px 24px 8px 58px;text-decoration:none;transition:color .3s,background-color .3s}.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{--neeto-ui-text-body2:15px;opacity:.75}@media screen and (min-width:1536px){.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{--neeto-ui-text-body2:16px}}.neeto-molecules-sidebar__sublink:hover{color:rgb(var(--neeto-ui-black));text-decoration:none}.neeto-molecules-sidebar__sublink:hover .neeto-molecules-sidebar__link-sub-count{opacity:1}.neeto-molecules-sidebar__sublink:focus,.neeto-molecules-sidebar__sublink:focus-visible{color:rgb(var(--neeto-ui-black));outline:none;text-decoration:none}.neeto-molecules-sidebar__sublink:focus .neeto-molecules-sidebar__link-sub-count,.neeto-molecules-sidebar__sublink:focus-visible .neeto-molecules-sidebar__link-sub-count{opacity:1}.neeto-molecules-sidebar__sublink.active,.neeto-molecules-sidebar__sublink:active{color:rgb(var(--neeto-ui-accent-800));font-weight:500;text-decoration:none}.neeto-molecules-sidebar__sublink.active .neeto-molecules-sidebar__link-sub-count,.neeto-molecules-sidebar__sublink:active .neeto-molecules-sidebar__link-sub-count{opacity:1}.neeto-molecules-sidebar__footer{margin-top:auto}.sidebar-featured-tooltip__content{border-radius:8px!important;box-shadow:var(--neeto-ui-shadow-sm)!important}.sidebar-featured-tooltip__content .tippy-content{padding:0}.sidebar-featured-tooltip{padding:12px;width:150px}.sidebar-featured-tooltip__icon-wrap{background-color:rgb(var(--neeto-ui-gray-100));border-radius:8px;height:40px;margin-bottom:8px;margin-left:auto;margin-right:auto;width:40px}.sidebar-featured-tooltip__title{margin-bottom:4px}.neeto-molecules-help-popup-wrapper,.neeto-molecules-product-switcher-popup-wrapper,.neeto-molecules-profile-popup-wrapper{border:1px solid rgb(var(--neeto-ui-gray-400));border-radius:var(--neeto-ui-rounded)!important;min-width:240px}.neeto-molecules-help-popup-wrapper .tippy-content,.neeto-molecules-product-switcher-popup-wrapper .tippy-content,.neeto-molecules-profile-popup-wrapper .tippy-content{padding:0}.neeto-molecules-help-popup-wrapper .tippy-svg-arrow,.neeto-molecules-product-switcher-popup-wrapper .tippy-svg-arrow,.neeto-molecules-profile-popup-wrapper .tippy-svg-arrow{display:none!important}.neeto-molecules-profile-popup__top-section{border-top-left-radius:var(--neeto-ui-rounded);border-top-right-radius:var(--neeto-ui-rounded)}.neeto-molecules-profile-sublist{border-top:1px solid rgb(var(--neeto-ui-gray-400))}.neeto-molecules-help-sublist,.neeto-molecules-profile-sublist{list-style:none;margin:0;padding:4px 0}.neeto-molecules-help-sublist__item,.neeto-molecules-profile-sublist__item{width:100%}.neeto-molecules-help-sublist__item-btn,.neeto-molecules-profile-sublist__item-btn{border-radius:0;justify-content:flex-end!important;min-height:40px;text-align:left}.neeto-molecules-help-sublist__item-btn.active,.neeto-molecules-profile-sublist__item-btn.active{background-color:rgb(var(--neeto-ui-gray-800));color:rgb(var(--neeto-ui-white))}.neeto-molecules-help-sublist__item-btn-icon svg path,.neeto-molecules-profile-sublist__item-btn-icon svg path{vector-effect:non-scaling-stroke}.neeto-molecules-help-sublist__item-btn span,.neeto-molecules-profile-sublist__item-btn span{align-items:center;display:flex;gap:8px}.neeto-molecules-sidebar__link-icon{position:relative}.neeto-molecules-sidebar__notif-count{position:absolute;right:-6px;top:-6px;z-index:1}.neeto-molecules-help-sublist__item-btn-count,.neeto-molecules-sidebar__notif-count{align-items:center;background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded-full);color:rgb(var(--neeto-ui-white));display:inline-flex;flex-shrink:0;font-size:var(--neeto-ui-text-xxs);height:15px;justify-content:center;text-align:center;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:15px}.neeto-molecules-product-switcher-popup-wrapper{height:calc(100vh - 16px);margin-bottom:8px;min-width:calc(100vw - 176px);overflow-y:auto}@media screen and (max-width:768px){.neeto-molecules-product-switcher-popup-wrapper{width:calc(100vw - 185px)!important}}.neeto-molecules-sidebar__backdrop{background-color:rgba(var(--neeto-ui-black),.4);height:100%;left:0;position:absolute;top:0;width:100%}@media screen and (min-width:769px){.neeto-molecules-sidebar__backdrop{display:none;visibility:hidden}}.neeto-molecules-sidebar-segments-header{padding-left:58px}.neeto-molecules-sidebar-segment{margin-bottom:0!important;padding:4px 24px 4px 58px}.neeto-molecules-sidebar.neeto-molecules-sidebar--focus-mode{padding-top:0}.neeto-molecules-sidebar.neeto-molecules-sidebar--focus-mode .neeto-molecules-sidebar__header{padding-top:24px}.neeto-molecules-sidebar.neeto-molecules-sidebar--focus-mode .neeto-molecules-sidebar__links{display:flex;flex-direction:column;height:calc(100vh - 160px);margin-bottom:0}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper{flex-grow:1;margin:0 0 10px!important;min-height:0;overflow-y:auto;padding:0 0 10px!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink-wrapper{padding:0!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{border-radius:0}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link{--neeto-ui-text-body1:18px;background-color:rgb(var(--neeto-ui-gray-100));color:rgb(var(--neeto-ui-black));cursor:pointer;font-weight:var(--neeto-ui-font-semibold);gap:4px;padding:12px 4px;position:sticky;top:0;z-index:1}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link-label,.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link-sub-label{--neeto-ui-text-body2:15px}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink{color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-medium);margin-bottom:0;padding-bottom:10px;padding-top:10px}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink.active{font-weight:var(--neeto-ui-font-semibold)}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{border-radius:0;padding-left:32px}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink{cursor:pointer;line-height:1.2;padding:8px 12px 8px 24px;position:relative}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink:hover{background-color:rgb(var(--neeto-ui-gray-100))}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink.active{background-color:rgb(var(--neeto-ui-accent-100))!important;color:rgb(var(--neeto-ui-black))!important;font-weight:var(--neeto-ui-font-medium)}.neeto-molecules-sidebar__link-unread-count{align-items:center;background-color:rgb(var(--neeto-ui-accent-500));border-radius:var(--neeto-ui-rounded-full);color:rgb(var(--neeto-ui-white));display:flex;flex-shrink:0;font-size:var(--neeto-ui-text-xxs);height:16px;justify-content:center;min-width:16px;padding-left:4px;padding-right:4px;position:absolute;right:-4px;top:-4px;-webkit-user-select:none;-moz-user-select:none;user-select:none}.neeto-ui-theme--dark .neeto-molecules-sidebar__logo>path{fill:rgb(var(--neeto-ui-black))}";
|
|
207
207
|
injectCss.n(css,{});
|
|
208
208
|
|
|
209
209
|
var Chevron = function Chevron(_ref) {
|
|
@@ -228,4 +228,4 @@ exports._Items = _Items;
|
|
|
228
228
|
exports.filterByPermissions = filterByPermissions;
|
|
229
229
|
exports.findCurrentConfigureNavLink = findCurrentConfigureNavLink;
|
|
230
230
|
exports.getSidebarStateLocalStorageKey = getSidebarStateLocalStorageKey;
|
|
231
|
-
//# sourceMappingURL=Chevron-
|
|
231
|
+
//# sourceMappingURL=Chevron-D9ITVEQr.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Chevron-DpYyQWkK.js","sources":["../../src/components/Sidebar/Components/Links/CheckPointNavLink.jsx","../../src/components/Sidebar/constants.js","../../src/components/Sidebar/utils.js","../../src/components/Sidebar/Components/Links/SubLink.jsx","../../src/components/Sidebar/Components/Links/Items.jsx","../../src/components/Sidebar/Components/Links/SelectedLink.jsx","../../src/components/Sidebar/Components/Chevron.jsx"],"sourcesContent":["import { useNavigationCheckpoints } from \"neetocommons/react-utils/useRegisterNavigationCheckpoint\";\nimport { NavLink } from \"react-router-dom\";\n\nconst CheckPointNavLinks = ({ checkpointKey, to, children, ...others }) => {\n const { [checkpointKey]: checkpoint } =\n useNavigationCheckpoints(checkpointKey);\n\n return (\n <NavLink to={checkpoint || to} {...others} key={to}>\n {children}\n </NavLink>\n );\n};\n\nexport default CheckPointNavLinks;\n","export const SUB_LINK_TYPES = {\n SYSTEM_VIEW: \"system_view\",\n SEGMENTS: \"segments\",\n};\n\nexport const SELECTED_NAV_LINK_ROUTE_STORAGE_KEY = \"selectedNavLinkRoute\";\n","import { isPresent, isNotEmpty } from \"neetocist\";\nimport { __, all, curry, equals, includes, is } from \"ramda\";\n\nexport const isSubRouteActive = (subRoute, location) => {\n const currentBrowserUrl = new URL(\n location.pathname + location.search + location.hash,\n window.location.origin\n );\n const targetUrl = new URL(subRoute, window.location.origin);\n\n const targetSearchParams = targetUrl.searchParams;\n const targetSearchKeys = Array.from(targetSearchParams.keys());\n\n return (\n all(\n key =>\n currentBrowserUrl.searchParams.get(key) === targetSearchParams.get(key),\n targetSearchKeys\n ) && equals(currentBrowserUrl.pathname, targetUrl.pathname)\n );\n};\n\nexport const getSidebarStateLocalStorageKey = () => {\n const user = globalProps.user?.email || globalProps.user?.phoneNumber;\n\n return `sidebarState-${user}`;\n};\n\nexport const filterByPermissions = curry(({ permissions }) => {\n if (permissions && isNotEmpty(permissions)) {\n return is(Array, permissions)\n ? permissions.some(includes(__, globalProps.permissions))\n : globalProps.permissions.includes(permissions);\n }\n\n return true;\n});\n\nexport const findCurrentConfigureNavLink = ({ navLinks, location }) =>\n navLinks.find(link => {\n const [linkPathname] = link.to?.split(\"?\") || [];\n\n return (\n isPresent(link.isConfigureNavLink) &&\n link.isConfigureNavLink &&\n location.pathname.startsWith(linkPathname)\n );\n });\n","import { hyphenate } from \"neetocist\";\nimport { Segments } from \"neetofilters\";\nimport { Typography } from \"neetoui\";\nimport { is } from \"ramda\";\n\nimport CheckPointNavLinks from \"./CheckPointNavLink\";\n\nimport { SUB_LINK_TYPES } from \"../../constants\";\nimport { isSubRouteActive } from \"../../utils\";\n\nconst SubLink = ({\n to,\n label,\n type = SUB_LINK_TYPES.SYSTEM_VIEW,\n count,\n isSectionHeader,\n isCountsLoading,\n \"data-cy\": dataCy,\n entity = \"\",\n columns = [],\n baseUrl,\n isActive,\n}) => {\n if (type === SUB_LINK_TYPES.SEGMENTS) {\n return <Segments {...{ baseUrl, columns, entity }} isIndependent={false} />;\n }\n\n const dataCyPrefix = dataCy || hyphenate(label);\n\n const renderCount = count => (count > 999 ? \"999+\" : count);\n\n const isSubLinkActive = () =>\n !isSectionHeader &&\n (is(Function, isActive) ? isActive() : isSubRouteActive(to, location));\n\n return (\n <CheckPointNavLinks\n {...{ to }}\n activeClassName=\"active\"\n className=\"neeto-molecules-sidebar__sublink neeto-ui-flex neeto-ui-items-center neeto-ui-select-none\"\n data-cy={`${dataCyPrefix}-sub-link`}\n isActive={isSubLinkActive}\n >\n <Typography\n className=\"neeto-molecules-sidebar__link-sub-label neeto-ui-flex-grow\"\n component=\"span\"\n data-cy={`${dataCyPrefix}-sub-link-label`}\n style=\"body2\"\n >\n {label}\n </Typography>\n <Typography\n className=\"neeto-molecules-sidebar__link-sub-count neeto-ui-flex-shrink-0\"\n component=\"span\"\n data-cy={`${dataCyPrefix}-sub-link-count`}\n style=\"body2\"\n >\n {isCountsLoading ? (\n <div className=\"neeto-ui-rounded neeto-ui-bg-gray-200 h-4 w-4 animate-pulse\" />\n ) : (\n renderCount(count)\n )}\n </Typography>\n </CheckPointNavLinks>\n );\n};\n\nexport default SubLink;\n","import { Fragment } from \"react\";\n\nimport { isPresent } from \"neetocist\";\n\nimport SubLink from \"./SubLink\";\n\nimport { filterByPermissions } from \"../../utils\";\n\nconst Items = ({ items, isSettingsItems = false, isCountsLoading }) => (\n <div\n className=\"neeto-molecules-sidebar__sublink-wrapper\"\n data-cy=\"sidebar-sub-link-wrapper\"\n >\n {items.filter(filterByPermissions).map((subItem, subIndex) => (\n <Fragment key={subIndex}>\n <SubLink\n {...{ ...subItem, isCountsLoading }}\n isActive={subItem.isActive}\n isSectionHeader={isPresent(subItem.item)}\n to={subItem.to ?? subItem.path}\n />\n {isSettingsItems && isPresent(subItem.items) && (\n <>\n <Items {...{ isSettingsItems }} items={subItem.items} />\n {items.length - 1 !== subIndex && (\n <hr className=\"neeto-molecules-sidebar__separator neeto-ui-border-gray-200\" />\n )}\n </>\n )}\n </Fragment>\n ))}\n </div>\n);\n\nexport default Items;\n","import classNames from \"classnames\";\nimport { hyphenize } from \"neetocommons/utils/general\";\nimport { Left } from \"neetoicons\";\nimport { Typography } from \"neetoui\";\nimport { omit } from \"ramda\";\n\nimport Items from \"./Items\";\n\nconst SelectedLink = ({\n navLink = { label: \"\", items: [], isConfigureNavLink: false },\n handleGoBack,\n isConfigureSidebar,\n}) => {\n const { label, items, isConfigureNavLink, ...otherProps } = navLink;\n\n return (\n <div\n className=\"neeto-molecules-sidebar__links neeto-molecules-sidebar__links--focus-mode neeto-molecules-sidebar__no-shrinkable\"\n data-cy=\"configure-nav-container\"\n >\n <div\n className=\"neeto-ui-flex neeto-ui-items-center neeto-ui-no-underline neeto-molecules-sidebar__link neeto-ui-border-b neeto-ui-border-gray-200\"\n onClick={handleGoBack}\n {...{ ...omit([\"icon\"], otherProps) }}\n >\n {isConfigureNavLink && (\n <span\n className=\"neeto-molecules-sidebar__link-icon\"\n data-cy={`${hyphenize(label)}-go-back-button`}\n data-testid={`${label}-go-back-button`}\n >\n <Left size={16} />\n </span>\n )}\n <Typography\n component=\"span\"\n style=\"body1\"\n className={classNames(\"neeto-molecules-sidebar__link-label\", {\n \"neeto-molecules-sidebar__configure-page-header\":\n isConfigureNavLink,\n [\"pl-4\"]: isConfigureSidebar,\n })}\n >\n {label}\n </Typography>\n </div>\n {items && <Items {...{ items }} isSettingsItems />}\n </div>\n );\n};\n\nexport default SelectedLink;\n","const Chevron = ({ style }) => (\n <svg {...{ style }} height=\"16\" viewBox=\"0 0 16 16\" width=\"16\">\n <path\n d=\"M7.07031 13.8887C7.2207 14.0391 7.40527 14.1211 7.62402 14.1211C8.06836 14.1211 8.41699 13.7725 8.41699 13.3281C8.41699 13.1094 8.32812 12.9043 8.17773 12.7539L3.37207 8.05762L8.17773 3.375C8.32812 3.21777 8.41699 3.0127 8.41699 2.80078C8.41699 2.35645 8.06836 2.00781 7.62402 2.00781C7.40527 2.00781 7.2207 2.08984 7.07031 2.24023L1.73828 7.44922C1.56055 7.62012 1.46484 7.8252 1.46484 8.06445C1.46484 8.29688 1.55371 8.49512 1.73828 8.67969L7.07031 13.8887ZM13.1748 13.8887C13.3252 14.0391 13.5098 14.1211 13.7354 14.1211C14.1797 14.1211 14.5283 13.7725 14.5283 13.3281C14.5283 13.1094 14.4395 12.9043 14.2891 12.7539L9.4834 8.05762L14.2891 3.375C14.4395 3.21777 14.5283 3.0127 14.5283 2.80078C14.5283 2.35645 14.1797 2.00781 13.7354 2.00781C13.5098 2.00781 13.3252 2.08984 13.1748 2.24023L7.84961 7.44922C7.66504 7.62012 7.57617 7.8252 7.56934 8.06445C7.56934 8.29688 7.66504 8.49512 7.84961 8.67969L13.1748 13.8887Z\"\n fill=\"currentColor\"\n />\n </svg>\n);\n\nexport default Chevron;\n"],"names":["CheckPointNavLinks","_ref","checkpointKey","to","children","others","_objectWithoutProperties","_excluded","_useNavigationCheckpo","useNavigationCheckpoints","checkpoint","_createElement","NavLink","_objectSpread","key","SUB_LINK_TYPES","SYSTEM_VIEW","SEGMENTS","SELECTED_NAV_LINK_ROUTE_STORAGE_KEY","isSubRouteActive","subRoute","location","currentBrowserUrl","URL","pathname","search","hash","window","origin","targetUrl","targetSearchParams","searchParams","targetSearchKeys","Array","from","keys","all","get","equals","getSidebarStateLocalStorageKey","_globalProps$user","_globalProps$user2","user","globalProps","email","phoneNumber","concat","filterByPermissions","curry","permissions","isNotEmpty","is","some","includes","__","findCurrentConfigureNavLink","_ref2","navLinks","find","link","_link$to","_ref3","split","_ref4","_slicedToArray","linkPathname","isPresent","isConfigureNavLink","startsWith","SubLink","label","_ref$type","type","count","isSectionHeader","isCountsLoading","dataCy","_ref$entity","entity","_ref$columns","columns","baseUrl","isActive","_jsx","Segments","isIndependent","dataCyPrefix","hyphenate","renderCount","isSubLinkActive","Function","_jsxs","activeClassName","className","Typography","component","style","Items","items","_ref$isSettingsItems","isSettingsItems","filter","map","subItem","subIndex","_subItem$to","Fragment","item","path","_Fragment","_Items","length","SelectedLink","_ref$navLink","navLink","handleGoBack","isConfigureSidebar","otherProps","onClick","omit","hyphenize","Left","size","classNames","_defineProperty","Chevron","height","viewBox","width","d","fill"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAGA,IAAMA,kBAAkB,GAAG,SAArBA,kBAAkBA,CAAAC,IAAA,EAAmD;AAAA,EAAA,IAA7CC,aAAa,GAAAD,IAAA,CAAbC,aAAa;IAAEC,EAAE,GAAAF,IAAA,CAAFE,EAAE;IAAEC,QAAQ,GAAAH,IAAA,CAARG,QAAQ;AAAKC,IAAAA,MAAM,GAAAC,wBAAA,CAAAL,IAAA,EAAAM,WAAA,CAAA,CAAA;AAClE,EAAA,IAAAC,qBAAA,GACEC,wDAAwB,CAACP,aAAa,CAAC;IADhBQ,UAAU,GAAAF,qBAAA,CAA1BN,aAAa,CAAA,CAAA;AAGtB,EAAA,oBACES,mBAAA,CAACC,sBAAO,EAAAC,eAAA,CAAAA,eAAA,CAAA;IAACV,EAAE,EAAEO,UAAU,IAAIP,EAAAA;AAAG,GAAA,EAAKE,MAAM,CAA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A;AAAOC,MAAAA,KAAK,EAALA,KAAK;MAAIE,eAAe,EAAA,IAAA;AAAA,KAAE,CAAC,CAAA;AAAA,GAC/C,CAAC,CAAA;AAEV;;;;;ACjDA,IAAMyB,OAAO,GAAG,SAAVA,OAAOA,CAAA5H,IAAA,EAAA;AAAA,EAAA,IAAM+F,KAAK,GAAA/F,IAAA,CAAL+F,KAAK,CAAA;AAAA,EAAA,oBACtBb,cAAA,CAAA,KAAA,EAAA;AAAWa,IAAAA,KAAK,EAALA,KAAK;AAAI8B,IAAAA,MAAM,EAAC,IAAI;AAACC,IAAAA,OAAO,EAAC,WAAW;AAACC,IAAAA,KAAK,EAAC,IAAI;AAAA5H,IAAAA,QAAA,eAC5D+E,cAAA,CAAA,MAAA,EAAA;AACE8C,MAAAA,CAAC,EAAC,y5BAAy5B;AAC35BC,MAAAA,IAAI,EAAC,cAAA;KACN,CAAA;AAAC,GACC,CAAC,CAAA;AAAA;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"Chevron-D9ITVEQr.js","sources":["../../src/components/Sidebar/Components/Links/CheckPointNavLink.jsx","../../src/components/Sidebar/constants.js","../../src/components/Sidebar/utils.js","../../src/components/Sidebar/Components/Links/SubLink.jsx","../../src/components/Sidebar/Components/Links/Items.jsx","../../src/components/Sidebar/Components/Links/SelectedLink.jsx","../../src/components/Sidebar/Components/Chevron.jsx"],"sourcesContent":["import { useNavigationCheckpoints } from \"neetocommons/react-utils/useRegisterNavigationCheckpoint\";\nimport { NavLink } from \"react-router-dom\";\n\nconst CheckPointNavLinks = ({ checkpointKey, to, children, ...others }) => {\n const { [checkpointKey]: checkpoint } =\n useNavigationCheckpoints(checkpointKey);\n\n return (\n <NavLink to={checkpoint || to} {...others} key={to}>\n {children}\n </NavLink>\n );\n};\n\nexport default CheckPointNavLinks;\n","export const SUB_LINK_TYPES = {\n SYSTEM_VIEW: \"system_view\",\n SEGMENTS: \"segments\",\n};\n\nexport const SELECTED_NAV_LINK_ROUTE_STORAGE_KEY = \"selectedNavLinkRoute\";\n","import { isPresent, isNotEmpty } from \"neetocist\";\nimport { __, all, curry, equals, includes, is } from \"ramda\";\n\nexport const isSubRouteActive = (subRoute, location) => {\n const currentBrowserUrl = new URL(\n location.pathname + location.search + location.hash,\n window.location.origin\n );\n const targetUrl = new URL(subRoute, window.location.origin);\n\n const targetSearchParams = targetUrl.searchParams;\n const targetSearchKeys = Array.from(targetSearchParams.keys());\n\n return (\n all(\n key =>\n currentBrowserUrl.searchParams.get(key) === targetSearchParams.get(key),\n targetSearchKeys\n ) && equals(currentBrowserUrl.pathname, targetUrl.pathname)\n );\n};\n\nexport const getSidebarStateLocalStorageKey = () => {\n const user = globalProps.user?.email || globalProps.user?.phoneNumber;\n\n return `sidebarState-${user}`;\n};\n\nexport const filterByPermissions = curry(({ permissions }) => {\n if (permissions && isNotEmpty(permissions)) {\n return is(Array, permissions)\n ? permissions.some(includes(__, globalProps.permissions))\n : globalProps.permissions.includes(permissions);\n }\n\n return true;\n});\n\nexport const findCurrentConfigureNavLink = ({ navLinks, location }) =>\n navLinks.find(link => {\n const [linkPathname] = link.to?.split(\"?\") || [];\n\n return (\n isPresent(link.isConfigureNavLink) &&\n link.isConfigureNavLink &&\n location.pathname.startsWith(linkPathname)\n );\n });\n","import { hyphenate } from \"neetocist\";\nimport { Segments } from \"neetofilters\";\nimport { Typography } from \"neetoui\";\nimport { is } from \"ramda\";\n\nimport CheckPointNavLinks from \"./CheckPointNavLink\";\n\nimport { SUB_LINK_TYPES } from \"../../constants\";\nimport { isSubRouteActive } from \"../../utils\";\n\nconst SubLink = ({\n to,\n label,\n type = SUB_LINK_TYPES.SYSTEM_VIEW,\n count,\n isSectionHeader,\n isCountsLoading,\n \"data-cy\": dataCy,\n entity = \"\",\n columns = [],\n baseUrl,\n isActive,\n}) => {\n if (type === SUB_LINK_TYPES.SEGMENTS) {\n return <Segments {...{ baseUrl, columns, entity }} isIndependent={false} />;\n }\n\n const dataCyPrefix = dataCy || hyphenate(label);\n\n const renderCount = count => (count > 999 ? \"999+\" : count);\n\n const isSubLinkActive = () =>\n !isSectionHeader &&\n (is(Function, isActive) ? isActive() : isSubRouteActive(to, location));\n\n return (\n <CheckPointNavLinks\n {...{ to }}\n activeClassName=\"active\"\n className=\"neeto-molecules-sidebar__sublink neeto-ui-flex neeto-ui-items-center neeto-ui-select-none\"\n data-cy={`${dataCyPrefix}-sub-link`}\n isActive={isSubLinkActive}\n >\n <Typography\n className=\"neeto-molecules-sidebar__link-sub-label neeto-ui-flex-grow\"\n component=\"span\"\n data-cy={`${dataCyPrefix}-sub-link-label`}\n style=\"body2\"\n >\n {label}\n </Typography>\n <Typography\n className=\"neeto-molecules-sidebar__link-sub-count neeto-ui-flex-shrink-0\"\n component=\"span\"\n data-cy={`${dataCyPrefix}-sub-link-count`}\n style=\"body2\"\n >\n {isCountsLoading ? (\n <div className=\"neeto-ui-rounded neeto-ui-bg-gray-200 h-4 w-4 animate-pulse\" />\n ) : (\n renderCount(count)\n )}\n </Typography>\n </CheckPointNavLinks>\n );\n};\n\nexport default SubLink;\n","import { Fragment } from \"react\";\n\nimport { isPresent } from \"neetocist\";\n\nimport SubLink from \"./SubLink\";\n\nimport { filterByPermissions } from \"../../utils\";\n\nconst Items = ({ items, isSettingsItems = false, isCountsLoading }) => (\n <div\n className=\"neeto-molecules-sidebar__sublink-wrapper\"\n data-cy=\"sidebar-sub-link-wrapper\"\n >\n {items.filter(filterByPermissions).map((subItem, subIndex) => (\n <Fragment key={subIndex}>\n <SubLink\n {...{ ...subItem, isCountsLoading }}\n isActive={subItem.isActive}\n isSectionHeader={isPresent(subItem.item)}\n to={subItem.to ?? subItem.path}\n />\n {isSettingsItems && isPresent(subItem.items) && (\n <>\n <Items {...{ isSettingsItems }} items={subItem.items} />\n {items.length - 1 !== subIndex && (\n <hr className=\"neeto-molecules-sidebar__separator neeto-ui-border-gray-200\" />\n )}\n </>\n )}\n </Fragment>\n ))}\n </div>\n);\n\nexport default Items;\n","import classNames from \"classnames\";\nimport { hyphenize } from \"neetocommons/utils/general\";\nimport { Left } from \"neetoicons\";\nimport { Typography } from \"neetoui\";\nimport { omit } from \"ramda\";\n\nimport Items from \"./Items\";\n\nconst SelectedLink = ({\n navLink = { label: \"\", items: [], isConfigureNavLink: false },\n handleGoBack,\n isConfigureSidebar,\n}) => {\n const { label, items, isConfigureNavLink, ...otherProps } = navLink;\n\n return (\n <div\n className=\"neeto-molecules-sidebar__links neeto-molecules-sidebar__links--focus-mode neeto-molecules-sidebar__no-shrinkable\"\n data-cy=\"configure-nav-container\"\n >\n <div\n className=\"neeto-ui-flex neeto-ui-items-center neeto-ui-no-underline neeto-molecules-sidebar__link neeto-ui-border-b neeto-ui-border-gray-200\"\n onClick={handleGoBack}\n {...{ ...omit([\"icon\"], otherProps) }}\n >\n {isConfigureNavLink && (\n <span\n className=\"neeto-molecules-sidebar__link-icon\"\n data-cy={`${hyphenize(label)}-go-back-button`}\n data-testid={`${label}-go-back-button`}\n >\n <Left size={16} />\n </span>\n )}\n <Typography\n component=\"span\"\n style=\"body1\"\n className={classNames(\"neeto-molecules-sidebar__link-label\", {\n \"neeto-molecules-sidebar__configure-page-header\":\n isConfigureNavLink,\n [\"pl-4\"]: isConfigureSidebar,\n })}\n >\n {label}\n </Typography>\n </div>\n {items && <Items {...{ items }} isSettingsItems />}\n </div>\n );\n};\n\nexport default SelectedLink;\n","const Chevron = ({ style }) => (\n <svg {...{ style }} height=\"16\" viewBox=\"0 0 16 16\" width=\"16\">\n <path\n d=\"M7.07031 13.8887C7.2207 14.0391 7.40527 14.1211 7.62402 14.1211C8.06836 14.1211 8.41699 13.7725 8.41699 13.3281C8.41699 13.1094 8.32812 12.9043 8.17773 12.7539L3.37207 8.05762L8.17773 3.375C8.32812 3.21777 8.41699 3.0127 8.41699 2.80078C8.41699 2.35645 8.06836 2.00781 7.62402 2.00781C7.40527 2.00781 7.2207 2.08984 7.07031 2.24023L1.73828 7.44922C1.56055 7.62012 1.46484 7.8252 1.46484 8.06445C1.46484 8.29688 1.55371 8.49512 1.73828 8.67969L7.07031 13.8887ZM13.1748 13.8887C13.3252 14.0391 13.5098 14.1211 13.7354 14.1211C14.1797 14.1211 14.5283 13.7725 14.5283 13.3281C14.5283 13.1094 14.4395 12.9043 14.2891 12.7539L9.4834 8.05762L14.2891 3.375C14.4395 3.21777 14.5283 3.0127 14.5283 2.80078C14.5283 2.35645 14.1797 2.00781 13.7354 2.00781C13.5098 2.00781 13.3252 2.08984 13.1748 2.24023L7.84961 7.44922C7.66504 7.62012 7.57617 7.8252 7.56934 8.06445C7.56934 8.29688 7.66504 8.49512 7.84961 8.67969L13.1748 13.8887Z\"\n fill=\"currentColor\"\n />\n </svg>\n);\n\nexport default Chevron;\n"],"names":["CheckPointNavLinks","_ref","checkpointKey","to","children","others","_objectWithoutProperties","_excluded","_useNavigationCheckpo","useNavigationCheckpoints","checkpoint","_createElement","NavLink","_objectSpread","key","SUB_LINK_TYPES","SYSTEM_VIEW","SEGMENTS","SELECTED_NAV_LINK_ROUTE_STORAGE_KEY","isSubRouteActive","subRoute","location","currentBrowserUrl","URL","pathname","search","hash","window","origin","targetUrl","targetSearchParams","searchParams","targetSearchKeys","Array","from","keys","all","get","equals","getSidebarStateLocalStorageKey","_globalProps$user","_globalProps$user2","user","globalProps","email","phoneNumber","concat","filterByPermissions","curry","permissions","isNotEmpty","is","some","includes","__","findCurrentConfigureNavLink","_ref2","navLinks","find","link","_link$to","_ref3","split","_ref4","_slicedToArray","linkPathname","isPresent","isConfigureNavLink","startsWith","SubLink","label","_ref$type","type","count","isSectionHeader","isCountsLoading","dataCy","_ref$entity","entity","_ref$columns","columns","baseUrl","isActive","_jsx","Segments","isIndependent","dataCyPrefix","hyphenate","renderCount","isSubLinkActive","Function","_jsxs","activeClassName","className","Typography","component","style","Items","items","_ref$isSettingsItems","isSettingsItems","filter","map","subItem","subIndex","_subItem$to","Fragment","item","path","_Fragment","_Items","length","SelectedLink","_ref$navLink","navLink","handleGoBack","isConfigureSidebar","otherProps","onClick","omit","hyphenize","Left","size","classNames","_defineProperty","Chevron","height","viewBox","width","d","fill"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAGA,IAAMA,kBAAkB,GAAG,SAArBA,kBAAkBA,CAAAC,IAAA,EAAmD;AAAA,EAAA,IAA7CC,aAAa,GAAAD,IAAA,CAAbC,aAAa;IAAEC,EAAE,GAAAF,IAAA,CAAFE,EAAE;IAAEC,QAAQ,GAAAH,IAAA,CAARG,QAAQ;AAAKC,IAAAA,MAAM,GAAAC,wBAAA,CAAAL,IAAA,EAAAM,WAAA,CAAA,CAAA;AAClE,EAAA,IAAAC,qBAAA,GACEC,wDAAwB,CAACP,aAAa,CAAC;IADhBQ,UAAU,GAAAF,qBAAA,CAA1BN,aAAa,CAAA,CAAA;AAGtB,EAAA,oBACES,mBAAA,CAACC,sBAAO,EAAAC,eAAA,CAAAA,eAAA,CAAA;IAACV,EAAE,EAAEO,UAAU,IAAIP,EAAAA;AAAG,GAAA,EAAKE,MAAM,CAAA,EAAA,EAAA,EAAA;AAAES,IAAAA,GAAG,EAAEX,EAAAA;AAAG,GAAA,CAAA,EAChDC,QACM,CAAC,CAAA;AAEd;;ACZO,IAAMW,cAAc,GAAG;AAC5BC,EAAAA,WAAW,EAAE,aAAa;AAC1BC,EAAAA,QAAQ,EAAE,UAAA;AACZ,CAAC,CAAA;AAEM,IAAMC,mCAAmC,GAAG;;ACF5C,IAAMC,gBAAgB,GAAG,SAAnBA,gBAAgBA,CAAIC,QAAQ,EAAEC,QAAQ,EAAK;EACtD,IAAMC,iBAAiB,GAAG,IAAIC,GAAG,CAC/BF,QAAQ,CAACG,QAAQ,GAAGH,QAAQ,CAACI,MAAM,GAAGJ,QAAQ,CAACK,IAAI,EACnDC,MAAM,CAACN,QAAQ,CAACO,MAClB,CAAC,CAAA;AACD,EAAA,IAAMC,SAAS,GAAG,IAAIN,GAAG,CAACH,QAAQ,EAAEO,MAAM,CAACN,QAAQ,CAACO,MAAM,CAAC,CA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@@ -7,7 +7,7 @@ var Button = require('@bigbinary/neetoui/Button');
|
|
|
7
7
|
var ramda = require('ramda');
|
|
8
8
|
var reactI18next = require('react-i18next');
|
|
9
9
|
var reactRouterDom = require('react-router-dom');
|
|
10
|
-
var Chevron = require('./Chevron-
|
|
10
|
+
var Chevron = require('./Chevron-D9ITVEQr.js');
|
|
11
11
|
var jsxRuntime = require('react/jsx-runtime');
|
|
12
12
|
require('@babel/runtime/helpers/defineProperty');
|
|
13
13
|
require('@babel/runtime/helpers/objectWithoutProperties');
|
|
@@ -25,7 +25,10 @@ var parseVariables = function parseVariables() {
|
|
|
25
25
|
label = variable.label,
|
|
26
26
|
variables = variable.variables;
|
|
27
27
|
if (category && variables) {
|
|
28
|
-
var parsedVariables = variables.map(ramda.
|
|
28
|
+
var parsedVariables = variables.map(ramda.mergeLeft({
|
|
29
|
+
category: category,
|
|
30
|
+
categoryLabel: label
|
|
31
|
+
}));
|
|
29
32
|
if (!categorySet.has(category)) {
|
|
30
33
|
categorySet.add(category);
|
|
31
34
|
groupedVariables.push({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DynamicVariables.js","sources":["../../src/components/DynamicVariables/utils.js","../../src/components/DynamicVariables/index.jsx"],"sourcesContent":["import { findBy } from \"neetocist\";\nimport { prop,
|
|
1
|
+
{"version":3,"file":"DynamicVariables.js","sources":["../../src/components/DynamicVariables/utils.js","../../src/components/DynamicVariables/index.jsx"],"sourcesContent":["import { findBy } from \"neetocist\";\nimport { prop, isEmpty, uniqBy, mergeLeft } from \"ramda\";\n\nexport const parseVariables = (variableArr = []) => {\n const uncategorized = [];\n const groupedVariables = [];\n const categorySet = new Set();\n\n variableArr.forEach(variable => {\n const { category, label, variables } = variable;\n if (category && variables) {\n const parsedVariables = variables.map(\n mergeLeft({ category, categoryLabel: label })\n );\n\n if (!categorySet.has(category)) {\n categorySet.add(category);\n groupedVariables.push({ label, variables: parsedVariables });\n } else {\n const existingGroup = findBy({ label }, groupedVariables);\n\n existingGroup.variables = uniqBy(\n prop(\"key\"),\n existingGroup.variables.concat(parsedVariables)\n );\n }\n } else {\n uncategorized.push(variable);\n }\n });\n\n if (!isEmpty(uncategorized)) {\n groupedVariables.push({\n label: !isEmpty(groupedVariables) ? \"Others\" : null,\n variables: uncategorized,\n });\n }\n\n return groupedVariables;\n};\n","import { Fragment } from \"react\";\n\nimport { noop } from \"neetocist\";\nimport { joinHyphenCase } from \"neetocommons/utils/general\";\nimport { Braces } from \"neetoicons\";\nimport { Dropdown, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\nimport { isEmpty } from \"ramda\";\n\nimport \"./dynamic-variables.scss\";\nimport { parseVariables } from \"./utils\";\n\nconst { Menu } = Dropdown;\n\nconst DynamicVariables = ({\n onVariableClick = noop,\n variables = [],\n buttonProps,\n ...dropdownProps\n}) => {\n if (isEmpty(variables)) {\n return null;\n }\n\n const parsedVariables = parseVariables(variables);\n\n return (\n <Dropdown\n appendTo={() => document.body}\n buttonStyle=\"secondary\"\n icon={Braces}\n strategy=\"fixed\"\n zIndex={99999}\n buttonProps={{\n \"data-testid\": \"variables-dropdown\",\n \"data-cy\": \"dynamic-variables-button\",\n ...buttonProps,\n }}\n {...dropdownProps}\n >\n <Menu>\n <div\n className=\"neeto-molecules-dynamic-variables\"\n data-testid=\"variables-list\"\n >\n {parsedVariables.map(({ label, variables }) => (\n <Fragment key={label}>\n {label && <Typography style=\"h6\">{label}</Typography>}\n <div\n className=\"neeto-molecules-dynamic-variables__list\"\n data-cy=\"dynamic-variables-list\"\n >\n {variables.map(item => (\n <button\n key={item.label}\n data-cy={joinHyphenCase(\n \"dynamic-variables-list-item\",\n item.label\n )}\n onClick={() => onVariableClick(item)}\n >\n {item.label}\n </button>\n ))}\n </div>\n </Fragment>\n ))}\n </div>\n </Menu>\n </Dropdown>\n );\n};\n\nDynamicVariables.propTypes = {\n /**\n * A function that is triggered when a dynamic variable button is clicked. It receives an object containing information about the clicked variable.\n */\n onVariableClick: PropTypes.func,\n /**\n * An array of objects, each representing a category or standalone variable, with the ability to define a label, key, and default value for each variable.\n */\n variables: PropTypes.arrayOf(\n PropTypes.shape({ label: PropTypes.string, key: PropTypes.string })\n ),\n};\n\nexport default DynamicVariables;\n"],"names":["parseVariables","variableArr","arguments","length","undefined","uncategorized","groupedVariables","categorySet","Set","forEach","variable","category","label","variables","parsedVariables","map","mergeLeft","categoryLabel","has","add","push","existingGroup","findBy","uniqBy","prop","concat","isEmpty","Menu","Dropdown","DynamicVariables","_ref","_ref$onVariableClick","onVariableClick","noop","_ref$variables","buttonProps","dropdownProps","_objectWithoutProperties","_excluded","_jsx","_objectSpread","appendTo","document","body","buttonStyle","icon","Braces","strategy","zIndex","children","className","_ref2","_jsxs","Fragment","Typography","style","item","joinHyphenCase","onClick"],"mappings":";;;;;;;;;;;;;;;;;AAGO,IAAMA,cAAc,GAAG,SAAjBA,cAAcA,GAAyB;AAAA,EAAA,IAArBC,WAAW,GAAAC,SAAA,CAAAC,MAAA,GAAA,CAAA,IAAAD,SAAA,CAAA,CAAA,CAAA,KAAAE,SAAA,GAAAF,SAAA,CAAA,CAAA,CAAA,GAAG,EAAE,CAAA;EAC7C,IAAMG,aAAa,GAAG,EAAE,CAAA;EACxB,IAAMC,gBAAgB,GAAG,EAAE,CAAA;AAC3B,EAAA,IAAMC,WAAW,GAAG,IAAIC,GAAG,EAAE,CAAA;AAE7BP,EAAAA,WAAW,CAACQ,OAAO,CAAC,UAAAC,QAAQ,EAAI;AAC9B,IAAA,IAAQC,QAAQ,GAAuBD,QAAQ,CAAvCC,QAAQ;MAAEC,KAAK,GAAgBF,QAAQ,CAA7BE,KAAK;MAAEC,SAAS,GAAKH,QAAQ,CAAtBG,SAAS,CAAA;IAClC,IAAIF,QAAQ,IAAIE,SAAS,EAAE;AACzB,MAAA,IAAMC,eAAe,GAAGD,SAAS,CAACE,GAAG,CACnCC,eAAS,CAAC;AAAEL,QAAAA,QAAQ,EAARA,QAAQ;AAAEM,QAAAA,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AACC,cAAQ,EAAA;AAAAJ,YAAAA,QAAA,EACNrC,CAAAA,KAAK,iBAAI2B,cAAA,CAACe,UAAU,EAAA;AAACC,cAAAA,KAAK,EAAC,IAAI;AAAAN,cAAAA,QAAA,EAAErC,KAAAA;aAAkB,CAAC,eACrD2B,cAAA,CAAA,KAAA,EAAA;AACEW,cAAAA,SAAS,EAAC,yCAAyC;AACnD,cAAA,SAAA,EAAQ,wBAAwB;AAAAD,cAAAA,QAAA,EAE/BpC,SAAS,CAACE,GAAG,CAAC,UAAAyC,IAAI,EAAA;AAAA,gBAAA,oBACjBjB,cAAA,CAAA,QAAA,EAAA;AAEE,kBAAA,SAAA,EAASkB,sBAAc,CACrB,6BAA6B,EAC7BD,IAAI,CAAC5C,KACP,CAAE;kBACF8C,OAAO,EAAE,SAATA,OAAOA,GAAA;oBAAA,OAAQ1B,eAAe,CAACwB,IAAI,CAAC,CAAA;mBAAC;kBAAAP,QAAA,EAEpCO,IAAI,CAAC5C,KAAAA;iBAPD4C,EAAAA,IAAI,CAAC5C,KAQJ,CAAC,CAAA;eACV,CAAA;AAAC,aACC,CAAC,CAAA;AAAA,WAAA,EAlBOA,KAmBL,CAAC,CAAA;SACZ,CAAA;OACE,CAAA;KACD,CAAA;AAAC,GAAA,CACC,CAAC,CAAA;AAEf;;;;"}
|
|
@@ -202,7 +202,7 @@ var shouldShowWhatsNew = function shouldShowWhatsNew() {
|
|
|
202
202
|
return window.location.hostname === "localhost" || currentUserEmail === "oliver@example.com" || (currentUserEmail === null || currentUserEmail === void 0 ? void 0 : currentUserEmail.endsWith("@bigbinary.com"));
|
|
203
203
|
};
|
|
204
204
|
var MY_ORGANIZATION_URL = "/auth/organization/edit";
|
|
205
|
-
var
|
|
205
|
+
var ENGAGE_WIDGET_TRIGGER_ID = "neetoengage-trigger";
|
|
206
206
|
var MENU_ITEMS_WITH_ICONS = ["Chat with support", "Help articles"];
|
|
207
207
|
var DEFAULT_HELP_LINK_PROPS = {
|
|
208
208
|
helpCenterProps: {
|
|
@@ -226,10 +226,10 @@ var DEFAULT_HELP_LINK_PROPS = {
|
|
|
226
226
|
}
|
|
227
227
|
};
|
|
228
228
|
var DEFAULT_MENU_LINK_PROPS = {
|
|
229
|
-
|
|
230
|
-
id:
|
|
229
|
+
engageProps: {
|
|
230
|
+
id: ENGAGE_WIDGET_TRIGGER_ID,
|
|
231
231
|
label: i18next.t("neetoMolecules.sidebar.helpLinks.whatsNew"),
|
|
232
|
-
"data-cy": "help-link-
|
|
232
|
+
"data-cy": "help-link-engage-button",
|
|
233
233
|
isVisible: shouldShowWhatsNew
|
|
234
234
|
},
|
|
235
235
|
keyboardShortcutProps: {
|
|
@@ -741,7 +741,7 @@ var ProfileButton = function ProfileButton(_ref) {
|
|
|
741
741
|
return !prev;
|
|
742
742
|
});
|
|
743
743
|
}
|
|
744
|
-
}), key === "
|
|
744
|
+
}), key === "engageProps" && changesCount && {
|
|
745
745
|
changesCount: changesCount
|
|
746
746
|
});
|
|
747
747
|
}).filter(function (_ref3) {
|