@bigbinary/neeto-molecules 1.15.42 → 1.15.44
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-67a58adc.js → Chevron-68d2b0e8.js} +2 -2
- package/dist/{Chevron-67a58adc.js.map → Chevron-68d2b0e8.js.map} +1 -1
- package/dist/ConfigurePageSidebar.js +1 -1
- package/dist/Onboarding.js +9 -3
- package/dist/Onboarding.js.map +1 -1
- package/dist/Rename.js +2 -1
- package/dist/Rename.js.map +1 -1
- package/dist/Sidebar.js +1 -1
- package/dist/cjs/{Chevron-3bf1f5f7.js → Chevron-166f3f91.js} +2 -2
- package/dist/cjs/{Chevron-3bf1f5f7.js.map → Chevron-166f3f91.js.map} +1 -1
- package/dist/cjs/ConfigurePageSidebar.js +1 -1
- package/dist/cjs/Onboarding.js +9 -3
- package/dist/cjs/Onboarding.js.map +1 -1
- package/dist/cjs/Rename.js +2 -1
- package/dist/cjs/Rename.js.map +1 -1
- package/dist/cjs/Sidebar.js +1 -1
- package/package.json +1 -1
- package/src/translations/en.json +3 -1
- package/types/Onboarding.d.ts +1 -0
|
@@ -167,7 +167,7 @@ var SelectedLink = function SelectedLink(_ref) {
|
|
|
167
167
|
}));
|
|
168
168
|
};
|
|
169
169
|
|
|
170
|
-
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{background-color:rgb(var(--neeto-ui-gray-100));border-right:1px solid rgb(var(--neeto-ui-gray-100));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::-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{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-header{font-weight:var(--neeto-ui-font-medium)!important}.neeto-molecules-sidebar__configure-page{border-right:1px solid rgb(var(--neeto-ui-gray-200));height:auto}.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__link span{font-weight:var(--neeto-ui-font-medium)}.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:20px;max-width:100%;width:auto}.neeto-molecules-sidebar__links{margin-bottom:40px}.neeto-molecules-sidebar__link{color:rgb(var(--neeto-ui-gray-800));gap:10px;padding:12px 24px;position:relative;text-decoration:none!important;transition:var(--neeto-ui-transition);width:100%}.neeto-molecules-sidebar__link-icon{flex-shrink:0;transition:var(--neeto-ui-transition)}.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{flex-grow:1;text-align:left}.neeto-molecules-sidebar__link:hover{background-color:rgb(var(--neeto-ui-gray-200));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-white));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link.active .neeto-molecules-sidebar__link-label{font-weight:var(--neeto-ui-font-medium)}.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-gray-800))}.neeto-molecules-sidebar__link--change-log{outline:none!important}.neeto-molecules-sidebar__sublink-wrapper{background-color:rgb(var(--neeto-ui-white));padding:4px 0}.neeto-molecules-sidebar__sublink{background-color:rgb(var(--neeto-ui-white));color:rgb(var(--neeto-ui-gray-700));cursor:pointer;gap:8px;padding:8px 24px 8px 58px;text-decoration:none;transition:all .3s}.neeto-molecules-sidebar__sublink:not(:last-child){margin-bottom:4px}.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{opacity:.75}.neeto-molecules-sidebar__sublink:hover{color:rgb(var(--neeto-ui-gray-800));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-gray-800));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-black));font-weight:var(--neeto-ui-font-medium);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;box-shadow:0 8px 10px 1px rgba(0,0,0,.14),0 3px 14px 2px rgba(0,0,0,.12),0 5px 5px -3px rgba(0,0,0,.2)!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{height:calc(100vh - 160px);margin-bottom:0;overflow:auto}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink-wrapper{margin:0!important;padding:0!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link{--neeto-ui-text-body2:16px;cursor:pointer;gap:4px;padding:12px 4px;position:sticky;top:0;z-index:1}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:15px;border-top:1px solid rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-medium);margin-bottom:0!important;padding-bottom:8px!important;padding-top:8px!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:13px;padding-left:40px!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink{cursor:pointer;margin-bottom:4px;padding:4px 4px 4px 30px!important;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-primary-100))!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink.active:before{background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded);content:\"\";height:100%;left:-1px;position:absolute;top:0;width:3px}";
|
|
170
|
+
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:70px}}.neeto-molecules-sidebar{background-color:rgb(var(--neeto-ui-gray-100));border-right:1px solid rgb(var(--neeto-ui-gray-100));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::-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{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-header{font-weight:var(--neeto-ui-font-medium)!important}.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__link span{font-weight:var(--neeto-ui-font-medium)}.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:20px;max-width:100%;width:auto}.neeto-molecules-sidebar__links{margin-bottom:40px}.neeto-molecules-sidebar__link{color:rgb(var(--neeto-ui-gray-800));gap:10px;padding:12px 24px;position:relative;text-decoration:none!important;transition:var(--neeto-ui-transition);width:100%}.neeto-molecules-sidebar__link-icon{flex-shrink:0;transition:var(--neeto-ui-transition)}.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{flex-grow:1;text-align:left}.neeto-molecules-sidebar__link:hover{background-color:rgb(var(--neeto-ui-gray-200));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-white));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link.active .neeto-molecules-sidebar__link-label{font-weight:var(--neeto-ui-font-medium)}.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-gray-800))}.neeto-molecules-sidebar__link--change-log{outline:none!important}.neeto-molecules-sidebar__sublink-wrapper{background-color:rgb(var(--neeto-ui-white));padding:4px 0}.neeto-molecules-sidebar__sublink{background-color:rgb(var(--neeto-ui-white));color:rgb(var(--neeto-ui-gray-700));cursor:pointer;gap:8px;padding:8px 24px 8px 58px;text-decoration:none;transition:all .3s}.neeto-molecules-sidebar__sublink:not(:last-child){margin-bottom:4px}.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{opacity:.75}.neeto-molecules-sidebar__sublink:hover{color:rgb(var(--neeto-ui-gray-800));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-gray-800));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-black));font-weight:var(--neeto-ui-font-medium);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;box-shadow:0 8px 10px 1px rgba(0,0,0,.14),0 3px 14px 2px rgba(0,0,0,.12),0 5px 5px -3px rgba(0,0,0,.2)!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{height:calc(100vh - 160px);margin-bottom:0;overflow:auto}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink-wrapper{margin:0!important;padding:0!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link{--neeto-ui-text-body2:16px;cursor:pointer;gap:4px;padding:12px 4px;position:sticky;top:0;z-index:1}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:15px;border-top:1px solid rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-medium);margin-bottom:0!important;padding-bottom:8px!important;padding-top:8px!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:13px;padding-left:40px!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink{cursor:pointer;margin-bottom:4px;padding:4px 4px 4px 30px!important;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-primary-100))!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink.active:before{background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded);content:\"\";height:100%;left:-1px;position:absolute;top:0;width:3px}";
|
|
171
171
|
n(css,{});
|
|
172
172
|
|
|
173
173
|
var Chevron = function Chevron(_ref) {
|
|
@@ -184,4 +184,4 @@ var Chevron = function Chevron(_ref) {
|
|
|
184
184
|
};
|
|
185
185
|
|
|
186
186
|
export { Chevron as C, Items as I, SelectedLink as S, CheckPointNavLinks as a, filterByPermissions as f, getSidebarStateLocalStorageKey as g };
|
|
187
|
-
//# sourceMappingURL=Chevron-
|
|
187
|
+
//# sourceMappingURL=Chevron-68d2b0e8.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Chevron-67a58adc.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 React from \"react\";\n\nimport { 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","import { 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","import React from \"react\";\n\nimport { hyphenate } from \"neetocist\";\nimport { Segments } from \"neetofilters\";\nimport { Typography } from \"neetoui\";\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}) => {\n if (type === SUB_LINK_TYPES.SEGMENTS) {\n return <Segments {...{ columns, entity }} isIndependent={false} />;\n }\n\n const dataCyPrefix = dataCy || hyphenate(label);\n\n const renderCount = count => (count > 999 ? \"999+\" : count);\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={() => !isSectionHeader && isSubRouteActive(to, location)}\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 React 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 <React.Fragment key={subIndex}>\n <SubLink\n {...{ ...subItem, isCountsLoading }}\n isSectionHeader={isPresent(subItem.item)}\n to={subItem.to ?? subItem.path}\n />\n {isSettingsItems && isPresent(subItem.items) && (\n <Items {...{ isSettingsItems }} items={subItem.items} />\n )}\n </React.Fragment>\n ))}\n </div>\n);\n\nexport default Items;\n","import React from \"react\";\n\nimport 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-bg-white neeto-ui-no-underline neeto-molecules-sidebar__link\"\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 />\n </span>\n )}\n <Typography\n component=\"span\"\n style=\"body2\"\n weight=\"normal\"\n className={classNames(\"neeto-molecules-sidebar__link-label\", {\n \"neeto-molecules-sidebar__configure-page-header\":\n isConfigureNavLink,\n [\"pl-6\"]: isConfigureSidebar,\n })}\n >\n {label}\n </Typography>\n </div>\n {items && <Items {...{ items }} isSettingsItems />}\n </div>\n );\n};\n\nexport default SelectedLink;\n","import React from \"react\";\n\nconst 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","React","createElement","NavLink","_extends","key","SUB_LINK_TYPES","SYSTEM_VIEW","SEGMENTS","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","__","SubLink","label","_ref$type","type","count","isSectionHeader","isCountsLoading","dataCy","_ref$entity","entity","_ref$columns","columns","Segments","isIndependent","dataCyPrefix","hyphenate","renderCount","activeClassName","className","isActive","Typography","component","style","Items","items","_ref$isSettingsItems","isSettingsItems","filter","map","subItem","subIndex","_subItem$to","Fragment","_objectSpread","isPresent","item","path","SelectedLink","_ref$navLink","navLink","isConfigureNavLink","handleGoBack","isConfigureSidebar","otherProps","onClick","omit","hyphenize","Left","weight","classNames","_defineProperty","Chevron","height","viewBox","width","d","fill"],"mappings":";;;;;;;;;;;;;;;;AAKA,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,wBAAwB,CAACP,aAAa,CAAC;IADhBQ,UAAU,GAAAF,qBAAA,CAA1BN,aAAa,CAAA,CAAA;AAGtB,EAAA,oBACES,cAAA,CAAAC,aAAA,CAACC,OAAO,EAAAC,QAAA,CAAA;IAACX,EAAE,EAAEO,UAAU,IAAIP,EAAAA;AAAG,GAAA,EAAKE,MAAM,EAAA;AAAEU,IAAAA,GAAG,EAAEZ,EAAAA;AAAG,GAAA,CAAA,EAChDC,QACM,CAAC,CAAA;AAEd;;ACdO,IAAMY,cAAc,GAAG;AAC5BC,EAAAA,WAAW,EAAE,aAAa;AAC1BC,EAAAA,QAAQ,EAAE,UAAA;AACZ,CAAC;;ACAM,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,C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,CACE,CAAC,CAAA;AAAA;;;;"}
|
|
1
|
+
{"version":3,"file":"Chevron-68d2b0e8.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 React from \"react\";\n\nimport { 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","import { 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","import React from \"react\";\n\nimport { hyphenate } from \"neetocist\";\nimport { Segments } from \"neetofilters\";\nimport { Typography } from \"neetoui\";\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}) => {\n if (type === SUB_LINK_TYPES.SEGMENTS) {\n return <Segments {...{ columns, entity }} isIndependent={false} />;\n }\n\n const dataCyPrefix = dataCy || hyphenate(label);\n\n const renderCount = count => (count > 999 ? \"999+\" : count);\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={() => !isSectionHeader && isSubRouteActive(to, location)}\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 React 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 <React.Fragment key={subIndex}>\n <SubLink\n {...{ ...subItem, isCountsLoading }}\n isSectionHeader={isPresent(subItem.item)}\n to={subItem.to ?? subItem.path}\n />\n {isSettingsItems && isPresent(subItem.items) && (\n <Items {...{ isSettingsItems }} items={subItem.items} />\n )}\n </React.Fragment>\n ))}\n </div>\n);\n\nexport default Items;\n","import React from \"react\";\n\nimport 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-bg-white neeto-ui-no-underline neeto-molecules-sidebar__link\"\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 />\n </span>\n )}\n <Typography\n component=\"span\"\n style=\"body2\"\n weight=\"normal\"\n className={classNames(\"neeto-molecules-sidebar__link-label\", {\n \"neeto-molecules-sidebar__configure-page-header\":\n isConfigureNavLink,\n [\"pl-6\"]: isConfigureSidebar,\n })}\n >\n {label}\n </Typography>\n </div>\n {items && <Items {...{ items }} isSettingsItems />}\n </div>\n );\n};\n\nexport default SelectedLink;\n","import React from \"react\";\n\nconst 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","React","createElement","NavLink","_extends","key","SUB_LINK_TYPES","SYSTEM_VIEW","SEGMENTS","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","__","SubLink","label","_ref$type","type","count","isSectionHeader","isCountsLoading","dataCy","_ref$entity","entity","_ref$columns","columns","Segments","isIndependent","dataCyPrefix","hyphenate","renderCount","activeClassName","className","isActive","Typography","component","style","Items","items","_ref$isSettingsItems","isSettingsItems","filter","map","subItem","subIndex","_subItem$to","Fragment","_objectSpread","isPresent","item","path","SelectedLink","_ref$navLink","navLink","isConfigureNavLink","handleGoBack","isConfigureSidebar","otherProps","onClick","omit","hyphenize","Left","weight","classNames","_defineProperty","Chevron","height","viewBox","width","d","fill"],"mappings":";;;;;;;;;;;;;;;;AAKA,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,wBAAwB,CAACP,aAAa,CAAC;IADhBQ,UAAU,GAAAF,qBAAA,CAA1BN,aAAa,CAAA,CAAA;AAGtB,EAAA,oBACES,cAAA,CAAAC,aAAA,CAACC,OAAO,EAAAC,QAAA,CAAA;IAACX,EAAE,EAAEO,UAAU,IAAIP,EAAAA;AAAG,GAAA,EAAKE,MAAM,EAAA;AAAEU,IAAAA,GAAG,EAAEZ,EAAAA;AAAG,GAAA,CAAA,EAChDC,QACM,CAAC,CAAA;AAEd;;ACdO,IAAMY,cAAc,GAAG;AAC5BC,EAAAA,WAAW,EAAE,aAAa;AAC1BC,EAAAA,QAAQ,EAAE,UAAA;AACZ,CAAC;;ACAM,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,GAA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@bigbinary/neetoui';
|
|
|
5
5
|
import { not } from 'ramda';
|
|
6
6
|
import { useTranslation } from 'react-i18next';
|
|
7
7
|
import { useHistory } from 'react-router-dom';
|
|
8
|
-
import { S as SelectedLink, C as Chevron } from './Chevron-
|
|
8
|
+
import { S as SelectedLink, C as Chevron } from './Chevron-68d2b0e8.js';
|
|
9
9
|
import './extends-093996c9.js';
|
|
10
10
|
import './defineProperty-549061a7.js';
|
|
11
11
|
import './objectWithoutProperties-a0edb288.js';
|
package/dist/Onboarding.js
CHANGED
|
@@ -75,7 +75,9 @@ CompletedScreen.propTypes = {
|
|
|
75
75
|
var HelpScreen = function HelpScreen(_ref) {
|
|
76
76
|
var buttonProps = _ref.buttonProps,
|
|
77
77
|
_ref$className = _ref.className,
|
|
78
|
-
className = _ref$className === void 0 ? "" : _ref$className
|
|
78
|
+
className = _ref$className === void 0 ? "" : _ref$className,
|
|
79
|
+
_ref$standalone = _ref.standalone,
|
|
80
|
+
standalone = _ref$standalone === void 0 ? false : _ref$standalone;
|
|
79
81
|
var _useTranslation = useTranslation(),
|
|
80
82
|
t = _useTranslation.t;
|
|
81
83
|
var _useBreakpoints = useBreakpoints(),
|
|
@@ -92,7 +94,9 @@ var HelpScreen = function HelpScreen(_ref) {
|
|
|
92
94
|
"data-cy": "onboarding-help-title",
|
|
93
95
|
"data-testid": "onboarding-help-title",
|
|
94
96
|
style: "h2"
|
|
95
|
-
}, t("neetoMolecules.onboarding.helpScreen.
|
|
97
|
+
}, standalone ? t("neetoMolecules.onboarding.helpScreen.welcomeToTitle", {
|
|
98
|
+
appName: globalProps.appName
|
|
99
|
+
}) : t("neetoMolecules.onboarding.helpScreen.title")), /*#__PURE__*/React__default.createElement(Typography, {
|
|
96
100
|
"data-cy": "onboarding-help-description",
|
|
97
101
|
"data-testid": "onboarding-help-description",
|
|
98
102
|
lineHeight: "normal",
|
|
@@ -108,7 +112,9 @@ var HelpScreen = function HelpScreen(_ref) {
|
|
|
108
112
|
}))), /*#__PURE__*/React__default.createElement(Button, _extends({
|
|
109
113
|
"data-cy": "onboarding-help-button",
|
|
110
114
|
"data-testid": "onboarding-help-button",
|
|
111
|
-
label: t("neetoMolecules.onboarding.helpScreen.
|
|
115
|
+
label: standalone ? t("neetoMolecules.onboarding.helpScreen.startUsingButton", {
|
|
116
|
+
appName: globalProps.appName
|
|
117
|
+
}) : t("neetoMolecules.onboarding.helpScreen.continueButton")
|
|
112
118
|
}, buttonProps))));
|
|
113
119
|
};
|
|
114
120
|
|
package/dist/Onboarding.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Onboarding.js","sources":["../src/components/Onboarding/CompletedScreen.jsx","../src/components/Onboarding/HelpScreen.jsx","../src/components/Onboarding/WelcomeScreen.jsx"],"sourcesContent":["import React from \"react\";\n\nimport classnames from \"classnames\";\nimport { isPresent } from \"neetocist\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst CompletedScreen = withT(\n ({ t, title, description, children, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-congratulations-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-emoji\"\n style=\"h1\"\n >\n 🎉\n </Typography>\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-title\"\n data-testid=\"onboarding-congratulations-title\"\n style=\"h1\"\n >\n <span className=\"neeto-ui-text-success-500\">\n {t(\"neetoMolecules.onboarding.congratulations\")}\n </span>\n <br />\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-description\"\n data-testid=\"onboarding-congratulations-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n {children}\n </div>\n {isPresent(buttonProps) && (\n <Button\n data-cy=\"onboarding-congratulations-button\"\n data-testid=\"onboarding-congratulations-button\"\n label={t(\"neetoMolecules.onboarding.startUsing\")}\n {...buttonProps}\n />\n )}\n </div>\n )\n);\n\nCompletedScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the completed screen\n */\n title: PropTypes.string,\n /**\n * Description of the completed screen\n */\n description: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),\n /**\n * Additional children elements to be rendered within the completed screen.\n */\n children: PropTypes.node,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default CompletedScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport useBreakpoints from \"neetocommons/react-utils/useBreakpoints\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\nimport { useTranslation } from \"react-i18next\";\n\nimport \"./onboarding.scss\";\n\nconst HelpScreen = ({ buttonProps, className = \"\" }) => {\n const { t } = useTranslation();\n const { isSize } = useBreakpoints();\n\n return (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-help-wrapper\"\n >\n <div className=\"mx-auto w-full max-w-2xl space-y-6\">\n <div className=\"space-y-3\">\n <Typography\n component=\"h1\"\n data-cy=\"onboarding-help-title\"\n data-testid=\"onboarding-help-title\"\n style=\"h2\"\n >\n {t(\"neetoMolecules.onboarding.helpScreen.title\")}\n </Typography>\n <Typography\n data-cy=\"onboarding-help-description\"\n data-testid=\"onboarding-help-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {t(\"neetoMolecules.onboarding.helpScreen.description\")}\n </Typography>\n <div className=\"w-full overflow-hidden\">\n {isSize(\"mobile\") ? (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-mobile_FpB8LKYj4.svg\"\n />\n ) : (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-desktop_aVe6ENdX97.svg\"\n />\n )}\n </div>\n </div>\n <Button\n data-cy=\"onboarding-help-button\"\n data-testid=\"onboarding-help-button\"\n label={t(\"neetoMolecules.onboarding.helpScreen.continueButton\")}\n {...buttonProps}\n />\n </div>\n </div>\n );\n};\n\nHelpScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default HelpScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { RightArrow } from \"neetoicons\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst WelcomeScreen = withT(\n ({ t, title, description, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-welcome-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-title\"\n data-testid=\"onboarding-welcome-title\"\n style=\"h1\"\n >\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-description\"\n data-testid=\"onboarding-welcome-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n </div>\n <Button\n data-cy=\"onboarding-welcome-button\"\n data-testid=\"onboarding-welcome-button\"\n icon={RightArrow}\n label={t(\"neetoMolecules.onboarding.getStarted\")}\n {...buttonProps}\n />\n </div>\n )\n);\n\nWelcomeScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the welcome screen\n */\n title: PropTypes.string,\n /**\n * Description of the welcome screen\n */\n description: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default WelcomeScreen;\n"],"names":["CompletedScreen","withT","_ref","t","title","description","children","buttonProps","_ref$className","className","React","createElement","classnames","Typography","style","lineHeight","isPresent","Button","_extends","label","propTypes","PropTypes","string","oneOfType","node","object","HelpScreen","_useTranslation","useTranslation","_useBreakpoints","useBreakpoints","isSize","component","alt","src","WelcomeScreen","icon","RightArrow"],"mappings":";;;;;;;;;;;;;;;AAUA,IAAMA,eAAe,GAAGC,KAAK,CAC3B,UAAAC,IAAA,EAAA;AAAA,EAAA,IAAGC,CAAC,GAAAD,IAAA,CAADC,CAAC;IAAEC,KAAK,GAAAF,IAAA,CAALE,KAAK;IAAEC,WAAW,GAAAH,IAAA,CAAXG,WAAW;IAAEC,QAAQ,GAAAJ,IAAA,CAARI,QAAQ;IAAEC,WAAW,GAAAL,IAAA,CAAXK,WAAW;IAAAC,cAAA,GAAAN,IAAA,CAAEO,SAAS;AAATA,IAAAA,SAAS,GAAAD,cAAA,KAAG,KAAA,CAAA,GAAA,EAAE,GAAAA,cAAA,CAAA;EAAA,oBAC7DE,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEF,IAAAA,SAAS,EAAEG,UAAU,CAAC,qCAAqC,EAAEH,SAAS,CAAE;IACxE,aAAY,EAAA,oCAAA;GAEZC,eAAAA,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKF,IAAAA,SAAS,EAAC,yCAAA;AAAyC,GAAA,eACtDC,cAAA,CAAAC,aAAA,CAACE,UAAU,EAAA;AACTJ,IAAAA,SAAS,EAAC,aAAa;AACvB,IAAA,SAAA,EAAQ,kCAAkC;AAC1CK,IAAAA,KAAK,EAAC,IAAA;AAAI,GAAA,EACX,cAEW,CAAC,eACbJ,cAAA,CAAAC,aAAA,CAACE,UAAU,EAAA;AACTJ,IAAAA,SAAS,EAAC,aAAa;AACvB,IAAA,SAAA,EAAQ,kCAAkC;AAC1C,IAAA,aAAA,EAAY,kCAAkC;AAC9CK,IAAAA,KAAK,EAAC,IAAA;GAENJ,eAAAA,cAAA,CAAAC,aAAA,CAAA,MAAA,EAAA;AA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AW,iBACVK,cAAA,CAAAC,aAAA,CAACE,UAAU,EAAA;AACTJ,IAAAA,SAAS,EAAC,aAAa;AACvB,IAAA,SAAA,EAAQ,gCAAgC;AACxC,IAAA,aAAA,EAAY,gCAAgC;AAC5CM,IAAAA,UAAU,EAAC,QAAQ;AACnBD,IAAAA,KAAK,EAAC,OAAA;GAELT,EAAAA,WACS,CAEX,CAAC,eACNK,cAAA,CAAAC,aAAA,CAACM,MAAM,EAAAC,QAAA,CAAA;AACL,IAAA,SAAA,EAAQ,2BAA2B;AACnC,IAAA,aAAA,EAAY,2BAA2B;AACvCkB,IAAAA,IAAI,EAAEC,UAAW;IACjBlB,KAAK,EAAEhB,CAAC,CAAC,sCAAsC,CAAA;GAC3CI,EAAAA,WAAW,CAChB,CACE,CAAC,CAAA;AAAA,CAEV,EAAC;AAED4B,aAAa,CAACf,SAAS,GAAG;AACxB;AACF;AACA;EACEX,SAAS,EAAEY,iBAAS,CAACC,MAAM;AAC3B;AACF;AACA;EACElB,KAAK,EAAEiB,iBAAS,CAACC,MAAM;AACvB;AACF;AACA;EACEjB,WAAW,EAAEgB,iBAAS,CAACC,MAAM;AAC7B;AACF;AACA;EACEf,WAAW,EAAEc,iBAAS,CAACI,MAAAA;AACzB,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"Onboarding.js","sources":["../src/components/Onboarding/CompletedScreen.jsx","../src/components/Onboarding/HelpScreen.jsx","../src/components/Onboarding/WelcomeScreen.jsx"],"sourcesContent":["import React from \"react\";\n\nimport classnames from \"classnames\";\nimport { isPresent } from \"neetocist\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst CompletedScreen = withT(\n ({ t, title, description, children, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-congratulations-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-emoji\"\n style=\"h1\"\n >\n 🎉\n </Typography>\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-title\"\n data-testid=\"onboarding-congratulations-title\"\n style=\"h1\"\n >\n <span className=\"neeto-ui-text-success-500\">\n {t(\"neetoMolecules.onboarding.congratulations\")}\n </span>\n <br />\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-description\"\n data-testid=\"onboarding-congratulations-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n {children}\n </div>\n {isPresent(buttonProps) && (\n <Button\n data-cy=\"onboarding-congratulations-button\"\n data-testid=\"onboarding-congratulations-button\"\n label={t(\"neetoMolecules.onboarding.startUsing\")}\n {...buttonProps}\n />\n )}\n </div>\n )\n);\n\nCompletedScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the completed screen\n */\n title: PropTypes.string,\n /**\n * Description of the completed screen\n */\n description: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),\n /**\n * Additional children elements to be rendered within the completed screen.\n */\n children: PropTypes.node,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default CompletedScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport useBreakpoints from \"neetocommons/react-utils/useBreakpoints\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\nimport { useTranslation } from \"react-i18next\";\n\nimport \"./onboarding.scss\";\n\nconst HelpScreen = ({ buttonProps, className = \"\", standalone = false }) => {\n const { t } = useTranslation();\n const { isSize } = useBreakpoints();\n\n return (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-help-wrapper\"\n >\n <div className=\"mx-auto w-full max-w-2xl space-y-6\">\n <div className=\"space-y-3\">\n <Typography\n component=\"h1\"\n data-cy=\"onboarding-help-title\"\n data-testid=\"onboarding-help-title\"\n style=\"h2\"\n >\n {standalone\n ? t(\"neetoMolecules.onboarding.helpScreen.welcomeToTitle\", {\n appName: globalProps.appName,\n })\n : t(\"neetoMolecules.onboarding.helpScreen.title\")}\n </Typography>\n <Typography\n data-cy=\"onboarding-help-description\"\n data-testid=\"onboarding-help-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {t(\"neetoMolecules.onboarding.helpScreen.description\")}\n </Typography>\n <div className=\"w-full overflow-hidden\">\n {isSize(\"mobile\") ? (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-mobile_FpB8LKYj4.svg\"\n />\n ) : (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-desktop_aVe6ENdX97.svg\"\n />\n )}\n </div>\n </div>\n <Button\n data-cy=\"onboarding-help-button\"\n data-testid=\"onboarding-help-button\"\n label={\n standalone\n ? t(\"neetoMolecules.onboarding.helpScreen.startUsingButton\", {\n appName: globalProps.appName,\n })\n : t(\"neetoMolecules.onboarding.helpScreen.continueButton\")\n }\n {...buttonProps}\n />\n </div>\n </div>\n );\n};\n\nHelpScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n /**\n * To specify if the help screen is standalone or not.\n */\n standalone: PropTypes.bool,\n};\n\nexport default HelpScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { RightArrow } from \"neetoicons\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst WelcomeScreen = withT(\n ({ t, title, description, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-welcome-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-title\"\n data-testid=\"onboarding-welcome-title\"\n style=\"h1\"\n >\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-description\"\n data-testid=\"onboarding-welcome-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n </div>\n <Button\n data-cy=\"onboarding-welcome-button\"\n data-testid=\"onboarding-welcome-button\"\n icon={RightArrow}\n label={t(\"neetoMolecules.onboarding.getStarted\")}\n {...buttonProps}\n />\n </div>\n )\n);\n\nWelcomeScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the welcome screen\n */\n title: PropTypes.string,\n /**\n * Description of the welcome screen\n */\n description: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default WelcomeScreen;\n"],"names":["CompletedScreen","withT","_ref","t","title","description","children","buttonProps","_ref$className","className","React","createElement","classnames","Typography","style","lineHeight","isPresent","Button","_extends","label","propTypes","PropTypes","string","oneOfType","node","object","HelpScreen","_ref$standalone","standalone","_useTranslation","useTranslation","_useBreakpoints","useBreakpoints","isSize","component","appName","globalProps","alt","src","WelcomeScreen","icon","RightArrow"],"mappings":";;;;;;;;;;;;;;;AAUA,IAAMA,eAAe,GAAGC,KAAK,CAC3B,UAAAC,IAAA,EAAA;AAAA,EAAA,IAAGC,CAAC,GAAAD,IAAA,CAADC,CAAC;IAAEC,KAAK,GAAAF,IAAA,CAALE,KAAK;IAAEC,WAAW,GAAAH,IAAA,CAAXG,WAAW;IAAEC,QAAQ,GAAAJ,IAAA,CAARI,QAAQ;IAAEC,WAAW,GAAAL,IAAA,CAAXK,WAAW;IAAAC,cAAA,GAAAN,IAAA,CAAEO,SAAS;AAATA,IAAAA,SAAS,GAAAD,cAAA,KAAG,KAAA,CAAA,GAAA,EAAE,GAAAA,cAAA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AEX,CAAC,eACNK,cAAA,CAAAC,aAAA,CAACM,MAAM,EAAAC,QAAA,CAAA;AACL,IAAA,SAAA,EAAQ,2BAA2B;AACnC,IAAA,aAAA,EAAY,2BAA2B;AACvCsB,IAAAA,IAAI,EAAEC,UAAW;IACjBtB,KAAK,EAAEhB,CAAC,CAAC,sCAAsC,CAAA;GAC3CI,EAAAA,WAAW,CAChB,CACE,CAAC,CAAA;AAAA,CAEV,EAAC;AAEDgC,aAAa,CAACnB,SAAS,GAAG;AACxB;AACF;AACA;EACEX,SAAS,EAAEY,iBAAS,CAACC,MAAM;AAC3B;AACF;AACA;EACElB,KAAK,EAAEiB,iBAAS,CAACC,MAAM;AACvB;AACF;AACA;EACEjB,WAAW,EAAEgB,iBAAS,CAACC,MAAM;AAC7B;AACF;AACA;EACEf,WAAW,EAAEc,iBAAS,CAACI,MAAAA;AACzB,CAAC;;;;"}
|
package/dist/Rename.js
CHANGED
package/dist/Rename.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Rename.js","sources":["../src/components/Rename/utils.js","../src/components/Rename/EditName.jsx","../src/components/Rename/RenameMenu.jsx","../src/components/Rename/ViewName.jsx","../src/components/Rename/index.jsx"],"sourcesContent":["export const mergeRefs =\n (...refs) =>\n node =>\n refs.forEach(ref =>\n typeof ref === \"function\" ? ref(node) : (ref.current = node)\n );\n","import React from \"react\";\n\nimport { withEventTargetValue } from \"neetocommons/utils/general\";\nimport useHotkeys from \"neetohotkeys\";\nimport { Check, Close } from \"neetoicons\";\nimport { Button, Input } from \"neetoui\";\nimport { isEmpty } from \"ramda\";\n\nimport { mergeRefs } from \"./utils\";\n\nconst Editor = ({\n placeholder,\n allowEmptySubmission,\n name,\n isLoading,\n handleRename,\n submitButtonProps,\n handleClose,\n cancelButtonProps,\n setName,\n inputProps,\n editMode,\n}) => {\n const closeRef = useHotkeys(\"escape\", event => handleClose({ event }), {\n mode: \"scoped\",\n enabled: editMode,\n });\n\n const submitRef = useHotkeys(\n [\"command+return\", \"return\"],\n event => {\n if (isEmpty(name) && !allowEmptySubmission) return;\n handleRename(event, name);\n },\n { mode: \"scoped\", enabled: editMode }\n );\n\n return (\n <div className=\"relative flex min-w-0 max-w-full flex-grow\">\n <span className=\"neeto-molecules-rename__input-width-maker\">\n {name.replace(/\\s/g, \".\") || placeholder}\n </span>\n <Input\n {...{ placeholder }}\n autoFocus\n className=\"neeto-molecules-rename__input absolute\"\n data-cy=\"form-rename-text-field\"\n data-testid=\"neeto-molecules-name-input\"\n ref={mergeRefs(closeRef, submitRef)}\n value={name}\n suffix={\n <div className=\"flex items-center justify-end\">\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-submit-button\"\n data-testid=\"neeto-molecules-rename-button\"\n disabled={(!allowEmptySubmission && isEmpty(name)) || isLoading}\n icon={Check}\n loading={isLoading}\n style=\"text\"\n onClick={event => handleRename(event, name)}\n {...submitButtonProps}\n />\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-close-button\"\n data-testid=\"neeto-molecules-cancel-button\"\n disabled={isLoading}\n icon={Close}\n style=\"text\"\n onClick={event => handleClose({ event })}\n {...cancelButtonProps}\n />\n </div>\n }\n onChange={withEventTargetValue(setName)}\n onClick={event => event.stopPropagation()}\n {...inputProps}\n label={null}\n />\n </div>\n );\n};\n\nexport default Editor;\n","import React from \"react\";\n\nimport { isPresent } from \"neetocist\";\nimport { withT } from \"neetocommons/react-utils\";\n\nimport MoreDropdown from \"components/MoreDropdown\";\n\nconst RenameMenu = withT(\n ({\n t,\n handleRenameClick,\n disabled,\n dropdownItems,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n }) => (\n <MoreDropdown\n dropdownButtonProps={{\n \"data-testid\": \"neeto-molecules-menu-button\",\n ...dropdownButtonProps,\n }}\n dropdownProps={{\n position: \"bottom-start\",\n onClick: event => event.stopPropagation(),\n strategy: \"fixed\",\n appendTo: () => document.body,\n ...dropdownProps,\n }}\n menuItems={[\n {\n \"data-cy\": \"form-rename-button\",\n onClick: handleRenameClick,\n label: t(\"neetoMolecules.common.actions.rename\"),\n isVisible: !disabled,\n key: \"edit-name-menu\",\n },\n {\n \"data-cy\": \"form-clone-button\",\n onClick: onClone,\n label: t(\"neetoMolecules.common.actions.clone\"),\n isVisible: isPresent(onClone),\n key: \"clone-entity-menu\",\n },\n {\n \"data-cy\": \"form-archive-button\",\n onClick: onArchiveStatusToggle,\n label: isArchived\n ? t(\"neetoMolecules.common.actions.unArchive\")\n : t(\"neetoMolecules.common.actions.archive\"),\n isVisible: isPresent(onArchiveStatusToggle),\n key: \"archive-entity-menu\",\n },\n {\n \"data-cy\": \"form-enable-button\",\n onClick: onDisableStatusToggle,\n label: isDisabled\n ? t(\"neetoMolecules.common.actions.enable\")\n : t(\"neetoMolecules.common.actions.disable\"),\n isVisible: isPresent(onDisableStatusToggle),\n key: \"enable-entity-menu\",\n },\n {\n \"data-cy\": \"form-delete-button\",\n onClick: onDelete,\n label: t(\"neetoMolecules.common.actions.delete\"),\n isVisible: isPresent(onDelete),\n key: \"delete-entity-menu\",\n },\n ...dropdownItems,\n ]}\n />\n )\n);\n\nexport default RenameMenu;\n","import React from \"react\";\n\nimport classNames from \"classnames\";\nimport { isNotEmpty, isPresent } from \"neetocist\";\nimport { Typography } from \"neetoui\";\n\nimport RenameMenu from \"./RenameMenu\";\n\nconst ViewName = ({\n disabled,\n textProps,\n formatText,\n dropdownItems,\n hideMenu,\n handleRenameClick,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n name,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n}) => {\n const isDefaultMenuCallbacksPresent =\n isPresent(onArchiveStatusToggle) ||\n isPresent(onDisableStatusToggle) ||\n isPresent(onDelete) ||\n isPresent(onClone);\n\n const isMenuVisible =\n !hideMenu &&\n (isNotEmpty(dropdownItems) || !disabled || isDefaultMenuCallbacksPresent);\n\n return (\n <>\n <Typography\n component=\"p\"\n data-cy=\"form-title\"\n data-testid=\"neeto-molecules-value-display\"\n style=\"body2\"\n className={classNames(\n \"neeto-molecules-rename__text neeto-molecules-rename__display-text w-full truncate\",\n {\n \"cursor-pointer\": !disabled,\n \"pointer-events-none cursor-text\": disabled,\n }\n )}\n onClick={handleRenameClick}\n {...textProps}\n >\n {typeof formatText === \"function\" ? formatText(name) : name}\n </Typography>\n {isMenuVisible && (\n <RenameMenu\n {...{\n disabled,\n dropdownButtonProps,\n dropdownItems,\n dropdownProps,\n handleRenameClick,\n isArchived,\n isDisabled,\n onArchiveStatusToggle,\n onClone,\n onDelete,\n onDisableStatusToggle,\n }}\n />\n )}\n </>\n );\n};\n\nexport default ViewName;\n","import React, { useState, useRef, useMemo } from \"react\";\n\nimport classnames from \"classnames\";\nimport { isNotEmpty, notEquals } from \"neetocist\";\nimport useOnClickOutside from \"neetocommons/react-utils/useOnClickOutside\";\nimport useStateWithDependency from \"neetocommons/react-utils/useStateWithDependency\";\nimport PropTypes from \"prop-types\";\nimport { isEmpty } from \"ramda\";\n\nimport Breadcrumbs from \"components/Breadcrumbs\";\n\nimport EditName from \"./EditName\";\nimport \"./rename.scss\";\nimport ViewName from \"./ViewName\";\n\nconst Rename = ({\n value,\n onRename,\n onClone,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onDelete,\n isArchived,\n isDisabled,\n isOpen = false,\n isLoading = false,\n placeholder = \"\",\n hideMenu = false,\n disabled = false,\n dropdownItems = [],\n breadcrumbs = [],\n textProps = {},\n inputProps = {},\n submitButtonProps = {},\n cancelButtonProps = {},\n className = \"\",\n allowEmptySubmission = false,\n defaultName = \"\",\n formatText,\n dropdownButtonProps = {},\n dropdownProps = {},\n}) => {\n const [name, setName] = useStateWithDependency(value ?? \"\");\n const [editMode, setEditMode] = useState(isOpen);\n const renameRef = useRef(null);\n\n const initialName = useMemo(() => name, [editMode]);\n\n useOnClickOutside(\n renameRef,\n () =>\n editMode &&\n handleClose({ saveOnOutsideClick: notEquals(name, initialName) })\n );\n\n const handleRename = (event, name) => {\n event?.stopPropagation();\n const newName = allowEmptySubmission && isEmpty(name) ? defaultName : name;\n setName(newName);\n onRename?.(newName);\n setEditMode(false);\n };\n\n const handleClose = ({ event = null, saveOnOutsideClick = false }) => {\n event?.stopPropagation();\n saveOnOutsideClick ? handleRename(event, name) : setName(value);\n setEditMode(false);\n };\n\n const handleRenameClick = event => {\n event.stopPropagation();\n !disabled && setEditMode(true);\n };\n\n const editNameProps = {\n allowEmptySubmission,\n cancelButtonProps,\n handleClose,\n handleRename,\n inputProps,\n isLoading,\n name,\n placeholder,\n setName,\n submitButtonProps,\n editMode,\n };\n\n const viewNameProps = {\n disabled,\n dropdownItems,\n formatText,\n handleRenameClick,\n hideMenu,\n name,\n isArchived,\n onArchiveStatusToggle,\n isDisabled,\n onDisableStatusToggle,\n onClone,\n onDelete,\n textProps,\n dropdownButtonProps,\n dropdownProps,\n };\n\n return (\n <div\n ref={renameRef}\n className={classnames(\n \"neeto-molecules-rename flex min-w-0 max-w-md flex-col items-start md:flex-row md:items-center\",\n className\n )}\n >\n {isNotEmpty(breadcrumbs) && (\n <Breadcrumbs\n {...{ breadcrumbs }}\n hasTrailingSeparator\n className=\"neeto-molecules-rename-breadcrumbs\"\n />\n )}\n <div className=\"relative flex max-w-full items-center gap-x-2\">\n {editMode ? (\n <EditName {...editNameProps} />\n ) : (\n <ViewName {...viewNameProps} />\n )}\n </div>\n </div>\n );\n};\n\nRename.propTypes = {\n /**\n * To provide additional classes to the component.\n */\n className: PropTypes.string,\n /**\n * To allow empty submission.\n */\n allowEmptySubmission: PropTypes.bool,\n /**\n * Default value to be used on empty submission.\n */\n defaultName: PropTypes.string,\n /**\n * To specify the text to be displayed in the component.\n */\n value: PropTypes.string,\n /**\n * To specify the function to be triggered when renamed.\n */\n onRename: PropTypes.func,\n /**\n * To specify the function to be triggered when Clone menu is clicked. The menu will be hidden if this prop is not set.\n */\n onClone: PropTypes.func,\n /**\n * To specify the function to be triggered when Archive menu is clicked. The menu will be hidden if this prop is not set.\n */\n onArchiveStatusToggle: PropTypes.func,\n /**\n * To specify the function to be triggered when Enable/Disable menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDisableStatusToggle: PropTypes.func,\n /**\n * To specify whether the entity is archived or not. The text in the menu will be changed based on this to Archive or Unarchive.\n */\n isArchived: PropTypes.bool,\n /**\n * To specify whether the entity is disabled or not. The text in the menu will be changed based on this to Enable or Disable.\n */\n isDisabled: PropTypes.bool,\n /**\n * To specify the function to be triggered when Delete menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDelete: PropTypes.func,\n /**\n * To specify whether edit mode is enabled or not.\n */\n isOpen: PropTypes.bool,\n /**\n * To specify whether the edit buttons are in loading state or not.\n */\n isLoading: PropTypes.bool,\n /**\n * To specify the placeholder for the input component in edit mode.\n */\n placeholder: PropTypes.string,\n /**\n * To specify whether the dropdown menu should be hidden or not.\n */\n hideMenu: PropTypes.bool,\n /**\n * To specify whether the rename option in dropdown should be enabled. If it is the only option in dropdown, the menu will be hidden.\n */\n disabled: PropTypes.bool,\n /**\n * To specify additional items for the dropdown menu.\n */\n dropdownItems: PropTypes.array,\n /**\n * To specify the breadcrumbs if used in the title of `Header` component.\n */\n breadcrumbs: PropTypes.arrayOf(\n PropTypes.shape({\n text: PropTypes.string,\n link: PropTypes.string,\n })\n ),\n /**\n * To override the properties of the Typography component that displays the `value`.\n */\n textProps: PropTypes.object,\n /**\n * To override the properties of the Input component in edit mode.\n */\n inputProps: PropTypes.object,\n /**\n * To format the value to display when not in edit mode.\n */\n formatText: PropTypes.func,\n /**\n * To override the properties of the submit button.\n */\n submitButtonProps: PropTypes.object,\n /**\n * To override the properties of the cancel button.\n */\n cancelButtonProps: PropTypes.object,\n};\n\nexport default Rename;\n"],"names":["mergeRefs","_len","arguments","length","refs","Array","_key","node","forEach","ref","current","Editor","_ref","placeholder","allowEmptySubmission","name","isLoading","handleRename","submitButtonProps","handleClose","cancelButtonProps","setName","inputProps","editMode","closeRef","useHotkeys","event","mode","enabled","submitRef","isEmpty","React","createElement","className","replace","Input","_extends","autoFocus","value","suffix","Button","disabled","icon","Check","loading","style","onClick","Close","onChange","withEventTargetValue","stopPropagation","label","RenameMenu","withT","t","handleRenameClick","dropdownItems","onArchiveStatusToggle","onDisableStatusToggle","onClone","onDelete","isArchived","isDisabled","dropdownButtonProps","dropdownProps","MoreDropdown","_objectSpread","position","strategy","appendTo","document","body","menuItems","isVisible","key","isPresent","concat","_toConsumableArray","ViewName","textProps","formatText","hideMenu","isDefaultMenuCallbacksPresent","isMenuVisible","isNotEmpty","Fragment","Typography","component","classNames","Rename","onRename","_ref$isOpen","isOpen","_ref$isLoading","_ref$placeholder","_ref$hideMenu","_ref$disabled","_ref$dropdownItems","_ref$breadcrumbs","breadcrumbs","_ref$textProps","_ref$inputProps","_ref$submitButtonProp","_ref$cancelButtonProp","_ref$className","_ref$allowEmptySubmis","_ref$defaultName","defaultName","_ref$dropdownButtonPr","_ref$dropdownProps","_useStateWithDependen","useStateWithDependency","_useStateWithDependen2","_slicedToArray","_useState","useState","_useState2","setEditMode","renameRef","useRef","initialName","useMemo","useOnClickOutside","saveOnOutsideClick","notEquals","newName","_ref2","_ref2$event","_ref2$saveOnOutsideCl","editNameProps","viewNameProps","classnames","Breadcrumbs","hasTrailingSeparator","EditName"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAO,IAAMA,SAAS,GACpB,SADWA,SAASA,GAAA;AAAA,EAAA,KAAA,IAAAC,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAChBC,IAAI,GAAAC,IAAAA,KAAA,CAAAJ,IAAA,GAAAK,IAAA,GAAA,CAAA,EAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA,EAAA,EAAA;AAAJF,IAAAA,IAAI,CAAAE,IAAA,CAAAJ,GAAAA,SAAA,CAAAI,IAAA,CAAA,CAAA;AAAA,GAAA;AAAA,EA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GAAG,EAAE6G,SAAU;AACfrF,IAAAA,SAAS,EAAEkG,UAAU,CACnB,+FAA+F,EAC/FlG,SACF,CAAA;GAECmD,EAAAA,UAAU,CAACe,WAAW,CAAC,iBACtBpE,cAAA,CAAAC,aAAA,CAACoG,WAAW,EAAA;AACJjC,IAAAA,WAAW,EAAXA,WAAW;IACjBkC,oBAAoB,EAAA,IAAA;AACpBpG,IAAAA,SAAS,EAAC,oCAAA;AAAoC,GAC/C,CACF,eACDF,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKC,IAAAA,SAAS,EAAC,+CAAA;GACZV,EAAAA,QAAQ,gBACPQ,cAAA,CAAAC,aAAA,CAACsG,MAAQ,EAAKL,aAAgB,CAAC,gBAE/BlG,cAAA,CAAAC,aAAA,CAAC8C,QAAQ,EAAKoD,aAAgB,CAE7B,CACF,CAAC,CAAA;AAEV;;;;"}
|
|
1
|
+
{"version":3,"file":"Rename.js","sources":["../src/components/Rename/utils.js","../src/components/Rename/EditName.jsx","../src/components/Rename/RenameMenu.jsx","../src/components/Rename/ViewName.jsx","../src/components/Rename/index.jsx"],"sourcesContent":["export const mergeRefs =\n (...refs) =>\n node =>\n refs.forEach(ref =>\n typeof ref === \"function\" ? ref(node) : (ref.current = node)\n );\n","import React from \"react\";\n\nimport { withEventTargetValue } from \"neetocommons/utils/general\";\nimport useHotkeys from \"neetohotkeys\";\nimport { Check, Close } from \"neetoicons\";\nimport { Button, Input } from \"neetoui\";\nimport { isEmpty } from \"ramda\";\n\nimport { mergeRefs } from \"./utils\";\n\nconst Editor = ({\n placeholder,\n allowEmptySubmission,\n name,\n isLoading,\n handleRename,\n submitButtonProps,\n handleClose,\n cancelButtonProps,\n setName,\n inputProps,\n editMode,\n}) => {\n const closeRef = useHotkeys(\"escape\", event => handleClose({ event }), {\n mode: \"scoped\",\n enabled: editMode,\n });\n\n const submitRef = useHotkeys(\n [\"command+return\", \"return\"],\n event => {\n if (isEmpty(name) && !allowEmptySubmission) return;\n handleRename(event, name);\n },\n { mode: \"scoped\", enabled: editMode }\n );\n\n return (\n <div className=\"relative flex min-w-0 max-w-full flex-grow\">\n <span className=\"neeto-molecules-rename__input-width-maker\">\n {name.replace(/\\s/g, \".\") || placeholder}\n </span>\n <Input\n {...{ placeholder }}\n autoFocus\n className=\"neeto-molecules-rename__input absolute\"\n data-cy=\"form-rename-text-field\"\n data-testid=\"neeto-molecules-name-input\"\n ref={mergeRefs(closeRef, submitRef)}\n value={name}\n suffix={\n <div className=\"flex items-center justify-end\">\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-submit-button\"\n data-testid=\"neeto-molecules-rename-button\"\n disabled={(!allowEmptySubmission && isEmpty(name)) || isLoading}\n icon={Check}\n loading={isLoading}\n style=\"text\"\n onClick={event => handleRename(event, name)}\n {...submitButtonProps}\n />\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-close-button\"\n data-testid=\"neeto-molecules-cancel-button\"\n disabled={isLoading}\n icon={Close}\n style=\"text\"\n onClick={event => handleClose({ event })}\n {...cancelButtonProps}\n />\n </div>\n }\n onChange={withEventTargetValue(setName)}\n onClick={event => event.stopPropagation()}\n {...inputProps}\n label={null}\n />\n </div>\n );\n};\n\nexport default Editor;\n","import React from \"react\";\n\nimport { isPresent } from \"neetocist\";\nimport { withT } from \"neetocommons/react-utils\";\n\nimport MoreDropdown from \"components/MoreDropdown\";\n\nconst RenameMenu = withT(\n ({\n t,\n handleRenameClick,\n disabled,\n dropdownItems,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n }) => (\n <MoreDropdown\n dropdownButtonProps={{\n \"data-testid\": \"neeto-molecules-menu-button\",\n ...dropdownButtonProps,\n }}\n dropdownProps={{\n position: \"bottom-start\",\n onClick: event => event.stopPropagation(),\n strategy: \"fixed\",\n appendTo: () => document.body,\n zIndex: \"99999\",\n ...dropdownProps,\n }}\n menuItems={[\n {\n \"data-cy\": \"form-rename-button\",\n onClick: handleRenameClick,\n label: t(\"neetoMolecules.common.actions.rename\"),\n isVisible: !disabled,\n key: \"edit-name-menu\",\n },\n {\n \"data-cy\": \"form-clone-button\",\n onClick: onClone,\n label: t(\"neetoMolecules.common.actions.clone\"),\n isVisible: isPresent(onClone),\n key: \"clone-entity-menu\",\n },\n {\n \"data-cy\": \"form-archive-button\",\n onClick: onArchiveStatusToggle,\n label: isArchived\n ? t(\"neetoMolecules.common.actions.unArchive\")\n : t(\"neetoMolecules.common.actions.archive\"),\n isVisible: isPresent(onArchiveStatusToggle),\n key: \"archive-entity-menu\",\n },\n {\n \"data-cy\": \"form-enable-button\",\n onClick: onDisableStatusToggle,\n label: isDisabled\n ? t(\"neetoMolecules.common.actions.enable\")\n : t(\"neetoMolecules.common.actions.disable\"),\n isVisible: isPresent(onDisableStatusToggle),\n key: \"enable-entity-menu\",\n },\n {\n \"data-cy\": \"form-delete-button\",\n onClick: onDelete,\n label: t(\"neetoMolecules.common.actions.delete\"),\n isVisible: isPresent(onDelete),\n key: \"delete-entity-menu\",\n },\n ...dropdownItems,\n ]}\n />\n )\n);\n\nexport default RenameMenu;\n","import React from \"react\";\n\nimport classNames from \"classnames\";\nimport { isNotEmpty, isPresent } from \"neetocist\";\nimport { Typography } from \"neetoui\";\n\nimport RenameMenu from \"./RenameMenu\";\n\nconst ViewName = ({\n disabled,\n textProps,\n formatText,\n dropdownItems,\n hideMenu,\n handleRenameClick,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n name,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n}) => {\n const isDefaultMenuCallbacksPresent =\n isPresent(onArchiveStatusToggle) ||\n isPresent(onDisableStatusToggle) ||\n isPresent(onDelete) ||\n isPresent(onClone);\n\n const isMenuVisible =\n !hideMenu &&\n (isNotEmpty(dropdownItems) || !disabled || isDefaultMenuCallbacksPresent);\n\n return (\n <>\n <Typography\n component=\"p\"\n data-cy=\"form-title\"\n data-testid=\"neeto-molecules-value-display\"\n style=\"body2\"\n className={classNames(\n \"neeto-molecules-rename__text neeto-molecules-rename__display-text w-full truncate\",\n {\n \"cursor-pointer\": !disabled,\n \"pointer-events-none cursor-text\": disabled,\n }\n )}\n onClick={handleRenameClick}\n {...textProps}\n >\n {typeof formatText === \"function\" ? formatText(name) : name}\n </Typography>\n {isMenuVisible && (\n <RenameMenu\n {...{\n disabled,\n dropdownButtonProps,\n dropdownItems,\n dropdownProps,\n handleRenameClick,\n isArchived,\n isDisabled,\n onArchiveStatusToggle,\n onClone,\n onDelete,\n onDisableStatusToggle,\n }}\n />\n )}\n </>\n );\n};\n\nexport default ViewName;\n","import React, { useState, useRef, useMemo } from \"react\";\n\nimport classnames from \"classnames\";\nimport { isNotEmpty, notEquals } from \"neetocist\";\nimport useOnClickOutside from \"neetocommons/react-utils/useOnClickOutside\";\nimport useStateWithDependency from \"neetocommons/react-utils/useStateWithDependency\";\nimport PropTypes from \"prop-types\";\nimport { isEmpty } from \"ramda\";\n\nimport Breadcrumbs from \"components/Breadcrumbs\";\n\nimport EditName from \"./EditName\";\nimport \"./rename.scss\";\nimport ViewName from \"./ViewName\";\n\nconst Rename = ({\n value,\n onRename,\n onClone,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onDelete,\n isArchived,\n isDisabled,\n isOpen = false,\n isLoading = false,\n placeholder = \"\",\n hideMenu = false,\n disabled = false,\n dropdownItems = [],\n breadcrumbs = [],\n textProps = {},\n inputProps = {},\n submitButtonProps = {},\n cancelButtonProps = {},\n className = \"\",\n allowEmptySubmission = false,\n defaultName = \"\",\n formatText,\n dropdownButtonProps = {},\n dropdownProps = {},\n}) => {\n const [name, setName] = useStateWithDependency(value ?? \"\");\n const [editMode, setEditMode] = useState(isOpen);\n const renameRef = useRef(null);\n\n const initialName = useMemo(() => name, [editMode]);\n\n useOnClickOutside(\n renameRef,\n () =>\n editMode &&\n handleClose({ saveOnOutsideClick: notEquals(name, initialName) })\n );\n\n const handleRename = (event, name) => {\n event?.stopPropagation();\n const newName = allowEmptySubmission && isEmpty(name) ? defaultName : name;\n setName(newName);\n onRename?.(newName);\n setEditMode(false);\n };\n\n const handleClose = ({ event = null, saveOnOutsideClick = false }) => {\n event?.stopPropagation();\n saveOnOutsideClick ? handleRename(event, name) : setName(value);\n setEditMode(false);\n };\n\n const handleRenameClick = event => {\n event.stopPropagation();\n !disabled && setEditMode(true);\n };\n\n const editNameProps = {\n allowEmptySubmission,\n cancelButtonProps,\n handleClose,\n handleRename,\n inputProps,\n isLoading,\n name,\n placeholder,\n setName,\n submitButtonProps,\n editMode,\n };\n\n const viewNameProps = {\n disabled,\n dropdownItems,\n formatText,\n handleRenameClick,\n hideMenu,\n name,\n isArchived,\n onArchiveStatusToggle,\n isDisabled,\n onDisableStatusToggle,\n onClone,\n onDelete,\n textProps,\n dropdownButtonProps,\n dropdownProps,\n };\n\n return (\n <div\n ref={renameRef}\n className={classnames(\n \"neeto-molecules-rename flex min-w-0 max-w-md flex-col items-start md:flex-row md:items-center\",\n className\n )}\n >\n {isNotEmpty(breadcrumbs) && (\n <Breadcrumbs\n {...{ breadcrumbs }}\n hasTrailingSeparator\n className=\"neeto-molecules-rename-breadcrumbs\"\n />\n )}\n <div className=\"relative flex max-w-full items-center gap-x-2\">\n {editMode ? (\n <EditName {...editNameProps} />\n ) : (\n <ViewName {...viewNameProps} />\n )}\n </div>\n </div>\n );\n};\n\nRename.propTypes = {\n /**\n * To provide additional classes to the component.\n */\n className: PropTypes.string,\n /**\n * To allow empty submission.\n */\n allowEmptySubmission: PropTypes.bool,\n /**\n * Default value to be used on empty submission.\n */\n defaultName: PropTypes.string,\n /**\n * To specify the text to be displayed in the component.\n */\n value: PropTypes.string,\n /**\n * To specify the function to be triggered when renamed.\n */\n onRename: PropTypes.func,\n /**\n * To specify the function to be triggered when Clone menu is clicked. The menu will be hidden if this prop is not set.\n */\n onClone: PropTypes.func,\n /**\n * To specify the function to be triggered when Archive menu is clicked. The menu will be hidden if this prop is not set.\n */\n onArchiveStatusToggle: PropTypes.func,\n /**\n * To specify the function to be triggered when Enable/Disable menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDisableStatusToggle: PropTypes.func,\n /**\n * To specify whether the entity is archived or not. The text in the menu will be changed based on this to Archive or Unarchive.\n */\n isArchived: PropTypes.bool,\n /**\n * To specify whether the entity is disabled or not. The text in the menu will be changed based on this to Enable or Disable.\n */\n isDisabled: PropTypes.bool,\n /**\n * To specify the function to be triggered when Delete menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDelete: PropTypes.func,\n /**\n * To specify whether edit mode is enabled or not.\n */\n isOpen: PropTypes.bool,\n /**\n * To specify whether the edit buttons are in loading state or not.\n */\n isLoading: PropTypes.bool,\n /**\n * To specify the placeholder for the input component in edit mode.\n */\n placeholder: PropTypes.string,\n /**\n * To specify whether the dropdown menu should be hidden or not.\n */\n hideMenu: PropTypes.bool,\n /**\n * To specify whether the rename option in dropdown should be enabled. If it is the only option in dropdown, the menu will be hidden.\n */\n disabled: PropTypes.bool,\n /**\n * To specify additional items for the dropdown menu.\n */\n dropdownItems: PropTypes.array,\n /**\n * To specify the breadcrumbs if used in the title of `Header` component.\n */\n breadcrumbs: PropTypes.arrayOf(\n PropTypes.shape({\n text: PropTypes.string,\n link: PropTypes.string,\n })\n ),\n /**\n * To override the properties of the Typography component that displays the `value`.\n */\n textProps: PropTypes.object,\n /**\n * To override the properties of the Input component in edit mode.\n */\n inputProps: PropTypes.object,\n /**\n * To format the value to display when not in edit mode.\n */\n formatText: PropTypes.func,\n /**\n * To override the properties of the submit button.\n */\n submitButtonProps: PropTypes.object,\n /**\n * To override the properties of the cancel button.\n */\n cancelButtonProps: PropTypes.object,\n};\n\nexport default Rename;\n"],"names":["mergeRefs","_len","arguments","length","refs","Array","_key","node","forEach","ref","current","Editor","_ref","placeholder","allowEmptySubmission","name","isLoading","handleRename","submitButtonProps","handleClose","cancelButtonProps","setName","inputProps","editMode","closeRef","useHotkeys","event","mode","enabled","submitRef","isEmpty","React","createElement","className","replace","Input","_extends","autoFocus","value","suffix","Button","disabled","icon","Check","loading","style","onClick","Close","onChange","withEventTargetValue","stopPropagation","label","RenameMenu","withT","t","handleRenameClick","dropdownItems","onArchiveStatusToggle","onDisableStatusToggle","onClone","onDelete","isArchived","isDisabled","dropdownButtonProps","dropdownProps","MoreDropdown","_objectSpread","position","strategy","appendTo","document","body","zIndex","menuItems","isVisible","key","isPresent","concat","_toConsumableArray","ViewName","textProps","formatText","hideMenu","isDefaultMenuCallbacksPresent","isMenuVisible","isNotEmpty","Fragment","Typography","component","classNames","Rename","onRename","_ref$isOpen","isOpen","_ref$isLoading","_ref$placeholder","_ref$hideMenu","_ref$disabled","_ref$dropdownItems","_ref$breadcrumbs","breadcrumbs","_ref$textProps","_ref$inputProps","_ref$submitButtonProp","_ref$cancelButtonProp","_ref$className","_ref$allowEmptySubmis","_ref$defaultName","defaultName","_ref$dropdownButtonPr","_ref$dropdownProps","_useStateWithDependen","useStateWithDependency","_useStateWithDependen2","_slicedToArray","_useState","useState","_useState2","setEditMode","renameRef","useRef","initialName","useMemo","useOnClickOutside","saveOnOutsideClick","notEquals","newName","_ref2","_ref2$event","_ref2$saveOnOutsideCl","editNameProps","viewNameProps","classnames","Breadcrumbs","hasTrailingSeparator","EditName"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAO,IAAMA,SAAS,GACpB,SADWA,SAASA,GAAA;AAAA,EAAA,KAAA,IAAAC,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAChBC,IAAI,GAAAC,IAAAA,KAAA,CAAAJ,IAAA,GAAAK,IAAA,GAAA,CAAA,EAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA,EAAA,EAAA;AAAJF,IAAAA,IAAI,CAAAE,IAAA,CAAAJ,GAAAA,SAAA,CAAAI,IAAA,CAAA,CAAA;AAAA,GAAA;AAAA,EAAA,OACR,UAAAC,IAAI,EAAA;AAAA,IAAA,OACFH,I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G,SAAU;AACftF,IAAAA,SAAS,EAAEmG,UAAU,CACnB,+FAA+F,EAC/FnG,SACF,CAAA;GAECoD,EAAAA,UAAU,CAACe,WAAW,CAAC,iBACtBrE,cAAA,CAAAC,aAAA,CAACqG,WAAW,EAAA;AACJjC,IAAAA,WAAW,EAAXA,WAAW;IACjBkC,oBAAoB,EAAA,IAAA;AACpBrG,IAAAA,SAAS,EAAC,oCAAA;AAAoC,GAC/C,CACF,eACDF,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKC,IAAAA,SAAS,EAAC,+CAAA;GACZV,EAAAA,QAAQ,gBACPQ,cAAA,CAAAC,aAAA,CAACuG,MAAQ,EAAKL,aAAgB,CAAC,gBAE/BnG,cAAA,CAAAC,aAAA,CAAC+C,QAAQ,EAAKoD,aAAgB,CAE7B,CACF,CAAC,CAAA;AAEV;;;;"}
|
package/dist/Sidebar.js
CHANGED
|
@@ -9,7 +9,7 @@ import { Typography, Button } from '@bigbinary/neetoui';
|
|
|
9
9
|
import { not, is, findLast } from 'ramda';
|
|
10
10
|
import { useTranslation } from 'react-i18next';
|
|
11
11
|
import { Link, useLocation, useHistory } from 'react-router-dom';
|
|
12
|
-
import { f as filterByPermissions, a as CheckPointNavLinks, I as Items, g as getSidebarStateLocalStorageKey, S as SelectedLink, C as Chevron } from './Chevron-
|
|
12
|
+
import { f as filterByPermissions, a as CheckPointNavLinks, I as Items, g as getSidebarStateLocalStorageKey, S as SelectedLink, C as Chevron } from './Chevron-68d2b0e8.js';
|
|
13
13
|
import useFetchNeetoApps from '@bigbinary/neeto-commons-frontend/react-utils/useFetchNeetoApps';
|
|
14
14
|
import * as ProductTypefaceLogos from '@bigbinary/neeto-icons/typeface-logos';
|
|
15
15
|
import { Neeto } from '@bigbinary/neeto-icons/typeface-logos';
|
|
@@ -174,7 +174,7 @@ var SelectedLink = function SelectedLink(_ref) {
|
|
|
174
174
|
}));
|
|
175
175
|
};
|
|
176
176
|
|
|
177
|
-
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{background-color:rgb(var(--neeto-ui-gray-100));border-right:1px solid rgb(var(--neeto-ui-gray-100));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::-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{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-header{font-weight:var(--neeto-ui-font-medium)!important}.neeto-molecules-sidebar__configure-page{border-right:1px solid rgb(var(--neeto-ui-gray-200));height:auto}.neeto-molecules-sidebar__configure-page .neeto-molecules-sidebar__link span{font-weight:var(--neeto-ui-font-medium)}.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:20px;max-width:100%;width:auto}.neeto-molecules-sidebar__links{margin-bottom:40px}.neeto-molecules-sidebar__link{color:rgb(var(--neeto-ui-gray-800));gap:10px;padding:12px 24px;position:relative;text-decoration:none!important;transition:var(--neeto-ui-transition);width:100%}.neeto-molecules-sidebar__link-icon{flex-shrink:0;transition:var(--neeto-ui-transition)}.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{flex-grow:1;text-align:left}.neeto-molecules-sidebar__link:hover{background-color:rgb(var(--neeto-ui-gray-200));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-white));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link.active .neeto-molecules-sidebar__link-label{font-weight:var(--neeto-ui-font-medium)}.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-gray-800))}.neeto-molecules-sidebar__link--change-log{outline:none!important}.neeto-molecules-sidebar__sublink-wrapper{background-color:rgb(var(--neeto-ui-white));padding:4px 0}.neeto-molecules-sidebar__sublink{background-color:rgb(var(--neeto-ui-white));color:rgb(var(--neeto-ui-gray-700));cursor:pointer;gap:8px;padding:8px 24px 8px 58px;text-decoration:none;transition:all .3s}.neeto-molecules-sidebar__sublink:not(:last-child){margin-bottom:4px}.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{opacity:.75}.neeto-molecules-sidebar__sublink:hover{color:rgb(var(--neeto-ui-gray-800));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-gray-800));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-black));font-weight:var(--neeto-ui-font-medium);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;box-shadow:0 8px 10px 1px rgba(0,0,0,.14),0 3px 14px 2px rgba(0,0,0,.12),0 5px 5px -3px rgba(0,0,0,.2)!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{height:calc(100vh - 160px);margin-bottom:0;overflow:auto}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink-wrapper{margin:0!important;padding:0!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link{--neeto-ui-text-body2:16px;cursor:pointer;gap:4px;padding:12px 4px;position:sticky;top:0;z-index:1}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:15px;border-top:1px solid rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-medium);margin-bottom:0!important;padding-bottom:8px!important;padding-top:8px!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:13px;padding-left:40px!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink{cursor:pointer;margin-bottom:4px;padding:4px 4px 4px 30px!important;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-primary-100))!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink.active:before{background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded);content:\"\";height:100%;left:-1px;position:absolute;top:0;width:3px}";
|
|
177
|
+
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:70px}}.neeto-molecules-sidebar{background-color:rgb(var(--neeto-ui-gray-100));border-right:1px solid rgb(var(--neeto-ui-gray-100));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::-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{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-header{font-weight:var(--neeto-ui-font-medium)!important}.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__link span{font-weight:var(--neeto-ui-font-medium)}.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:20px;max-width:100%;width:auto}.neeto-molecules-sidebar__links{margin-bottom:40px}.neeto-molecules-sidebar__link{color:rgb(var(--neeto-ui-gray-800));gap:10px;padding:12px 24px;position:relative;text-decoration:none!important;transition:var(--neeto-ui-transition);width:100%}.neeto-molecules-sidebar__link-icon{flex-shrink:0;transition:var(--neeto-ui-transition)}.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{flex-grow:1;text-align:left}.neeto-molecules-sidebar__link:hover{background-color:rgb(var(--neeto-ui-gray-200));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-white));color:rgb(var(--neeto-ui-black))}.neeto-molecules-sidebar__link.active .neeto-molecules-sidebar__link-label{font-weight:var(--neeto-ui-font-medium)}.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-gray-800))}.neeto-molecules-sidebar__link--change-log{outline:none!important}.neeto-molecules-sidebar__sublink-wrapper{background-color:rgb(var(--neeto-ui-white));padding:4px 0}.neeto-molecules-sidebar__sublink{background-color:rgb(var(--neeto-ui-white));color:rgb(var(--neeto-ui-gray-700));cursor:pointer;gap:8px;padding:8px 24px 8px 58px;text-decoration:none;transition:all .3s}.neeto-molecules-sidebar__sublink:not(:last-child){margin-bottom:4px}.neeto-molecules-sidebar__sublink .neeto-molecules-sidebar__link-sub-count{opacity:.75}.neeto-molecules-sidebar__sublink:hover{color:rgb(var(--neeto-ui-gray-800));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-gray-800));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-black));font-weight:var(--neeto-ui-font-medium);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;box-shadow:0 8px 10px 1px rgba(0,0,0,.14),0 3px 14px 2px rgba(0,0,0,.12),0 5px 5px -3px rgba(0,0,0,.2)!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{height:calc(100vh - 160px);margin-bottom:0;overflow:auto}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink-wrapper{margin:0!important;padding:0!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__link{--neeto-ui-text-body2:16px;cursor:pointer;gap:4px;padding:12px 4px;position:sticky;top:0;z-index:1}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:15px;border-top:1px solid rgb(var(--neeto-ui-gray-200));color:rgb(var(--neeto-ui-black));font-weight:var(--neeto-ui-font-medium);margin-bottom:0!important;padding-bottom:8px!important;padding-top:8px!important}.neeto-molecules-sidebar__links--focus-mode>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper>.neeto-molecules-sidebar__sublink-wrapper .neeto-molecules-sidebar__sublink{--neeto-ui-text-body2:13px;padding-left:40px!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink{cursor:pointer;margin-bottom:4px;padding:4px 4px 4px 30px!important;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-primary-100))!important}.neeto-molecules-sidebar__links--focus-mode .neeto-molecules-sidebar__sublink.active:before{background-color:rgb(var(--neeto-ui-primary-500));border-radius:var(--neeto-ui-rounded);content:\"\";height:100%;left:-1px;position:absolute;top:0;width:3px}";
|
|
178
178
|
injectCss.n(css,{});
|
|
179
179
|
|
|
180
180
|
var Chevron = function Chevron(_ref) {
|
|
@@ -196,4 +196,4 @@ exports.Items = Items;
|
|
|
196
196
|
exports.SelectedLink = SelectedLink;
|
|
197
197
|
exports.filterByPermissions = filterByPermissions;
|
|
198
198
|
exports.getSidebarStateLocalStorageKey = getSidebarStateLocalStorageKey;
|
|
199
|
-
//# sourceMappingURL=Chevron-
|
|
199
|
+
//# sourceMappingURL=Chevron-166f3f91.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Chevron-3bf1f5f7.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 React from \"react\";\n\nimport { 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","import { 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","import React from \"react\";\n\nimport { hyphenate } from \"neetocist\";\nimport { Segments } from \"neetofilters\";\nimport { Typography } from \"neetoui\";\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}) => {\n if (type === SUB_LINK_TYPES.SEGMENTS) {\n return <Segments {...{ columns, entity }} isIndependent={false} />;\n }\n\n const dataCyPrefix = dataCy || hyphenate(label);\n\n const renderCount = count => (count > 999 ? \"999+\" : count);\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={() => !isSectionHeader && isSubRouteActive(to, location)}\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 React 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 <React.Fragment key={subIndex}>\n <SubLink\n {...{ ...subItem, isCountsLoading }}\n isSectionHeader={isPresent(subItem.item)}\n to={subItem.to ?? subItem.path}\n />\n {isSettingsItems && isPresent(subItem.items) && (\n <Items {...{ isSettingsItems }} items={subItem.items} />\n )}\n </React.Fragment>\n ))}\n </div>\n);\n\nexport default Items;\n","import React from \"react\";\n\nimport 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-bg-white neeto-ui-no-underline neeto-molecules-sidebar__link\"\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 />\n </span>\n )}\n <Typography\n component=\"span\"\n style=\"body2\"\n weight=\"normal\"\n className={classNames(\"neeto-molecules-sidebar__link-label\", {\n \"neeto-molecules-sidebar__configure-page-header\":\n isConfigureNavLink,\n [\"pl-6\"]: isConfigureSidebar,\n })}\n >\n {label}\n </Typography>\n </div>\n {items && <Items {...{ items }} isSettingsItems />}\n </div>\n );\n};\n\nexport default SelectedLink;\n","import React from \"react\";\n\nconst 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","React","createElement","NavLink","_extends","key","SUB_LINK_TYPES","SYSTEM_VIEW","SEGMENTS","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","__","SubLink","label","_ref$type","type","count","isSectionHeader","isCountsLoading","dataCy","_ref$entity","entity","_ref$columns","columns","Segments","isIndependent","dataCyPrefix","hyphenate","renderCount","activeClassName","className","isActive","Typography","component","style","Items","items","_ref$isSettingsItems","isSettingsItems","filter","map","subItem","subIndex","_subItem$to","Fragment","_objectSpread","isPresent","item","path","SelectedLink","_ref$navLink","navLink","isConfigureNavLink","handleGoBack","isConfigureSidebar","otherProps","onClick","omit","hyphenize","Left","weight","classNames","_defineProperty","Chevron","height","viewBox","width","d","fill"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAKA,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,gDAAA,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,yBAAA,CAAAC,aAAA,CAACC,sBAAO,EAAAC,iBAAA,CAAA;IAACX,EAAE,EAAEO,UAAU,IAAIP,EAAAA;AAAG,GAAA,EAAKE,MAAM,EA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CAAC,CAAA;AAEV;;;;;AClDA,IAAMyB,OAAO,GAAG,SAAVA,OAAOA,CAAAzG,IAAA,EAAA;AAAA,EAAA,IAAM4E,KAAK,GAAA5E,IAAA,CAAL4E,KAAK,CAAA;EAAA,oBACtBlE,yBAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAWiE,IAAAA,KAAK,EAALA,KAAK;AAAI8B,IAAAA,MAAM,EAAC,IAAI;AAACC,IAAAA,OAAO,EAAC,WAAW;AAACC,IAAAA,KAAK,EAAC,IAAA;GACxDlG,eAAAA,yBAAA,CAAAC,aAAA,CAAA,MAAA,EAAA;AACEkG,IAAAA,CAAC,EAAC,y5BAAy5B;AAC35BC,IAAAA,IAAI,EAAC,cAAA;AAAc,GACpB,CACE,CAAC,CAAA;AAAA;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"Chevron-166f3f91.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 React from \"react\";\n\nimport { 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","import { 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","import React from \"react\";\n\nimport { hyphenate } from \"neetocist\";\nimport { Segments } from \"neetofilters\";\nimport { Typography } from \"neetoui\";\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}) => {\n if (type === SUB_LINK_TYPES.SEGMENTS) {\n return <Segments {...{ columns, entity }} isIndependent={false} />;\n }\n\n const dataCyPrefix = dataCy || hyphenate(label);\n\n const renderCount = count => (count > 999 ? \"999+\" : count);\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={() => !isSectionHeader && isSubRouteActive(to, location)}\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 React 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 <React.Fragment key={subIndex}>\n <SubLink\n {...{ ...subItem, isCountsLoading }}\n isSectionHeader={isPresent(subItem.item)}\n to={subItem.to ?? subItem.path}\n />\n {isSettingsItems && isPresent(subItem.items) && (\n <Items {...{ isSettingsItems }} items={subItem.items} />\n )}\n </React.Fragment>\n ))}\n </div>\n);\n\nexport default Items;\n","import React from \"react\";\n\nimport 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-bg-white neeto-ui-no-underline neeto-molecules-sidebar__link\"\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 />\n </span>\n )}\n <Typography\n component=\"span\"\n style=\"body2\"\n weight=\"normal\"\n className={classNames(\"neeto-molecules-sidebar__link-label\", {\n \"neeto-molecules-sidebar__configure-page-header\":\n isConfigureNavLink,\n [\"pl-6\"]: isConfigureSidebar,\n })}\n >\n {label}\n </Typography>\n </div>\n {items && <Items {...{ items }} isSettingsItems />}\n </div>\n );\n};\n\nexport default SelectedLink;\n","import React from \"react\";\n\nconst 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","React","createElement","NavLink","_extends","key","SUB_LINK_TYPES","SYSTEM_VIEW","SEGMENTS","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","__","SubLink","label","_ref$type","type","count","isSectionHeader","isCountsLoading","dataCy","_ref$entity","entity","_ref$columns","columns","Segments","isIndependent","dataCyPrefix","hyphenate","renderCount","activeClassName","className","isActive","Typography","component","style","Items","items","_ref$isSettingsItems","isSettingsItems","filter","map","subItem","subIndex","_subItem$to","Fragment","_objectSpread","isPresent","item","path","SelectedLink","_ref$navLink","navLink","isConfigureNavLink","handleGoBack","isConfigureSidebar","otherProps","onClick","omit","hyphenize","Left","weight","classNames","_defineProperty","Chevron","height","viewBox","width","d","fill"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAKA,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,gDAAA,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,yBAAA,CAAAC,aAAA,CAACC,sBAAO,EAAAC,iBAAA,CAAA;IAACX,EAAE,EAAEO,UAAU,IAAIP,EAAAA;AAAG,GAAA,EAAKE,MAAM,EAAA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AC,CAAA;AAEV;;;;;AClDA,IAAMyB,OAAO,GAAG,SAAVA,OAAOA,CAAAzG,IAAA,EAAA;AAAA,EAAA,IAAM4E,KAAK,GAAA5E,IAAA,CAAL4E,KAAK,CAAA;EAAA,oBACtBlE,yBAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAWiE,IAAAA,KAAK,EAALA,KAAK;AAAI8B,IAAAA,MAAM,EAAC,IAAI;AAACC,IAAAA,OAAO,EAAC,WAAW;AAACC,IAAAA,KAAK,EAAC,IAAA;GACxDlG,eAAAA,yBAAA,CAAAC,aAAA,CAAA,MAAA,EAAA;AACEkG,IAAAA,CAAC,EAAC,y5BAAy5B;AAC35BC,IAAAA,IAAI,EAAC,cAAA;AAAc,GACpB,CACE,CAAC,CAAA;AAAA;;;;;;;;;"}
|
|
@@ -7,7 +7,7 @@ var neetoui = require('@bigbinary/neetoui');
|
|
|
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-166f3f91.js');
|
|
11
11
|
require('./extends-1b35a664.js');
|
|
12
12
|
require('./defineProperty-886ed289.js');
|
|
13
13
|
require('./objectWithoutProperties-2fed2d7d.js');
|
package/dist/cjs/Onboarding.js
CHANGED
|
@@ -86,7 +86,9 @@ CompletedScreen.propTypes = {
|
|
|
86
86
|
var HelpScreen = function HelpScreen(_ref) {
|
|
87
87
|
var buttonProps = _ref.buttonProps,
|
|
88
88
|
_ref$className = _ref.className,
|
|
89
|
-
className = _ref$className === void 0 ? "" : _ref$className
|
|
89
|
+
className = _ref$className === void 0 ? "" : _ref$className,
|
|
90
|
+
_ref$standalone = _ref.standalone,
|
|
91
|
+
standalone = _ref$standalone === void 0 ? false : _ref$standalone;
|
|
90
92
|
var _useTranslation = reactI18next.useTranslation(),
|
|
91
93
|
t = _useTranslation.t;
|
|
92
94
|
var _useBreakpoints = useBreakpoints__default["default"](),
|
|
@@ -103,7 +105,9 @@ var HelpScreen = function HelpScreen(_ref) {
|
|
|
103
105
|
"data-cy": "onboarding-help-title",
|
|
104
106
|
"data-testid": "onboarding-help-title",
|
|
105
107
|
style: "h2"
|
|
106
|
-
}, t("neetoMolecules.onboarding.helpScreen.
|
|
108
|
+
}, standalone ? t("neetoMolecules.onboarding.helpScreen.welcomeToTitle", {
|
|
109
|
+
appName: globalProps.appName
|
|
110
|
+
}) : t("neetoMolecules.onboarding.helpScreen.title")), /*#__PURE__*/React__default["default"].createElement(neetoui.Typography, {
|
|
107
111
|
"data-cy": "onboarding-help-description",
|
|
108
112
|
"data-testid": "onboarding-help-description",
|
|
109
113
|
lineHeight: "normal",
|
|
@@ -119,7 +123,9 @@ var HelpScreen = function HelpScreen(_ref) {
|
|
|
119
123
|
}))), /*#__PURE__*/React__default["default"].createElement(neetoui.Button, _extends._extends({
|
|
120
124
|
"data-cy": "onboarding-help-button",
|
|
121
125
|
"data-testid": "onboarding-help-button",
|
|
122
|
-
label: t("neetoMolecules.onboarding.helpScreen.
|
|
126
|
+
label: standalone ? t("neetoMolecules.onboarding.helpScreen.startUsingButton", {
|
|
127
|
+
appName: globalProps.appName
|
|
128
|
+
}) : t("neetoMolecules.onboarding.helpScreen.continueButton")
|
|
123
129
|
}, buttonProps))));
|
|
124
130
|
};
|
|
125
131
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Onboarding.js","sources":["../../src/components/Onboarding/CompletedScreen.jsx","../../src/components/Onboarding/HelpScreen.jsx","../../src/components/Onboarding/WelcomeScreen.jsx"],"sourcesContent":["import React from \"react\";\n\nimport classnames from \"classnames\";\nimport { isPresent } from \"neetocist\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst CompletedScreen = withT(\n ({ t, title, description, children, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-congratulations-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-emoji\"\n style=\"h1\"\n >\n 🎉\n </Typography>\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-title\"\n data-testid=\"onboarding-congratulations-title\"\n style=\"h1\"\n >\n <span className=\"neeto-ui-text-success-500\">\n {t(\"neetoMolecules.onboarding.congratulations\")}\n </span>\n <br />\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-description\"\n data-testid=\"onboarding-congratulations-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n {children}\n </div>\n {isPresent(buttonProps) && (\n <Button\n data-cy=\"onboarding-congratulations-button\"\n data-testid=\"onboarding-congratulations-button\"\n label={t(\"neetoMolecules.onboarding.startUsing\")}\n {...buttonProps}\n />\n )}\n </div>\n )\n);\n\nCompletedScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the completed screen\n */\n title: PropTypes.string,\n /**\n * Description of the completed screen\n */\n description: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),\n /**\n * Additional children elements to be rendered within the completed screen.\n */\n children: PropTypes.node,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default CompletedScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport useBreakpoints from \"neetocommons/react-utils/useBreakpoints\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\nimport { useTranslation } from \"react-i18next\";\n\nimport \"./onboarding.scss\";\n\nconst HelpScreen = ({ buttonProps, className = \"\" }) => {\n const { t } = useTranslation();\n const { isSize } = useBreakpoints();\n\n return (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-help-wrapper\"\n >\n <div className=\"mx-auto w-full max-w-2xl space-y-6\">\n <div className=\"space-y-3\">\n <Typography\n component=\"h1\"\n data-cy=\"onboarding-help-title\"\n data-testid=\"onboarding-help-title\"\n style=\"h2\"\n >\n {t(\"neetoMolecules.onboarding.helpScreen.title\")}\n </Typography>\n <Typography\n data-cy=\"onboarding-help-description\"\n data-testid=\"onboarding-help-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {t(\"neetoMolecules.onboarding.helpScreen.description\")}\n </Typography>\n <div className=\"w-full overflow-hidden\">\n {isSize(\"mobile\") ? (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-mobile_FpB8LKYj4.svg\"\n />\n ) : (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-desktop_aVe6ENdX97.svg\"\n />\n )}\n </div>\n </div>\n <Button\n data-cy=\"onboarding-help-button\"\n data-testid=\"onboarding-help-button\"\n label={t(\"neetoMolecules.onboarding.helpScreen.continueButton\")}\n {...buttonProps}\n />\n </div>\n </div>\n );\n};\n\nHelpScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default HelpScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { RightArrow } from \"neetoicons\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst WelcomeScreen = withT(\n ({ t, title, description, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-welcome-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-title\"\n data-testid=\"onboarding-welcome-title\"\n style=\"h1\"\n >\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-description\"\n data-testid=\"onboarding-welcome-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n </div>\n <Button\n data-cy=\"onboarding-welcome-button\"\n data-testid=\"onboarding-welcome-button\"\n icon={RightArrow}\n label={t(\"neetoMolecules.onboarding.getStarted\")}\n {...buttonProps}\n />\n </div>\n )\n);\n\nWelcomeScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the welcome screen\n */\n title: PropTypes.string,\n /**\n * Description of the welcome screen\n */\n description: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default WelcomeScreen;\n"],"names":["CompletedScreen","withT","_ref","t","title","description","children","buttonProps","_ref$className","className","React","createElement","classnames","Typography","style","lineHeight","isPresent","Button","_extends","label","propTypes","PropTypes","string","oneOfType","node","object","HelpScreen","_useTranslation","useTranslation","_useBreakpoints","useBreakpoints","isSize","component","alt","src","WelcomeScreen","icon","RightArrow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAUA,IAAMA,eAAe,GAAGC,yBAAK,CAC3B,UAAAC,IAAA,EAAA;AAAA,EAAA,IAAGC,CAAC,GAAAD,IAAA,CAADC,CAAC;IAAEC,KAAK,GAAAF,IAAA,CAALE,KAAK;IAAEC,WAAW,GAAAH,IAAA,CAAXG,WAAW;IAAEC,QAAQ,GAAAJ,IAAA,CAARI,QAAQ;IAAEC,WAAW,GAAAL,IAAA,CAAXK,WAAW;IAAAC,cAAA,GAAAN,IAAA,CAAEO,SAAS;AAATA,IAAAA,SAAS,GAAAD,cAAA,KAAG,KAAA,CAAA,GAAA,EAAE,GAAAA,cAAA,CAAA;EAAA,oBAC7DE,yBAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEF,IAAAA,SAAS,EAAEG,8BAAU,CAAC,qCAAqC,E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AS,CAACC,MAAM;AACvB;AACF;AACA;EACEjB,WAAW,EAAEgB,uBAAS,CAACC,MAAM;AAC7B;AACF;AACA;EACEf,WAAW,EAAEc,uBAAS,CAACI,MAAAA;AACzB,CAAC;;;;;;"}
|
|
1
|
+
{"version":3,"file":"Onboarding.js","sources":["../../src/components/Onboarding/CompletedScreen.jsx","../../src/components/Onboarding/HelpScreen.jsx","../../src/components/Onboarding/WelcomeScreen.jsx"],"sourcesContent":["import React from \"react\";\n\nimport classnames from \"classnames\";\nimport { isPresent } from \"neetocist\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst CompletedScreen = withT(\n ({ t, title, description, children, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-congratulations-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-emoji\"\n style=\"h1\"\n >\n 🎉\n </Typography>\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-title\"\n data-testid=\"onboarding-congratulations-title\"\n style=\"h1\"\n >\n <span className=\"neeto-ui-text-success-500\">\n {t(\"neetoMolecules.onboarding.congratulations\")}\n </span>\n <br />\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-congratulations-description\"\n data-testid=\"onboarding-congratulations-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n {children}\n </div>\n {isPresent(buttonProps) && (\n <Button\n data-cy=\"onboarding-congratulations-button\"\n data-testid=\"onboarding-congratulations-button\"\n label={t(\"neetoMolecules.onboarding.startUsing\")}\n {...buttonProps}\n />\n )}\n </div>\n )\n);\n\nCompletedScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the completed screen\n */\n title: PropTypes.string,\n /**\n * Description of the completed screen\n */\n description: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),\n /**\n * Additional children elements to be rendered within the completed screen.\n */\n children: PropTypes.node,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default CompletedScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport useBreakpoints from \"neetocommons/react-utils/useBreakpoints\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\nimport { useTranslation } from \"react-i18next\";\n\nimport \"./onboarding.scss\";\n\nconst HelpScreen = ({ buttonProps, className = \"\", standalone = false }) => {\n const { t } = useTranslation();\n const { isSize } = useBreakpoints();\n\n return (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-help-wrapper\"\n >\n <div className=\"mx-auto w-full max-w-2xl space-y-6\">\n <div className=\"space-y-3\">\n <Typography\n component=\"h1\"\n data-cy=\"onboarding-help-title\"\n data-testid=\"onboarding-help-title\"\n style=\"h2\"\n >\n {standalone\n ? t(\"neetoMolecules.onboarding.helpScreen.welcomeToTitle\", {\n appName: globalProps.appName,\n })\n : t(\"neetoMolecules.onboarding.helpScreen.title\")}\n </Typography>\n <Typography\n data-cy=\"onboarding-help-description\"\n data-testid=\"onboarding-help-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {t(\"neetoMolecules.onboarding.helpScreen.description\")}\n </Typography>\n <div className=\"w-full overflow-hidden\">\n {isSize(\"mobile\") ? (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-mobile_FpB8LKYj4.svg\"\n />\n ) : (\n <img\n alt=\"\"\n src=\"https://ik.imagekit.io/d9mvewbju/Commons/help-desktop_aVe6ENdX97.svg\"\n />\n )}\n </div>\n </div>\n <Button\n data-cy=\"onboarding-help-button\"\n data-testid=\"onboarding-help-button\"\n label={\n standalone\n ? t(\"neetoMolecules.onboarding.helpScreen.startUsingButton\", {\n appName: globalProps.appName,\n })\n : t(\"neetoMolecules.onboarding.helpScreen.continueButton\")\n }\n {...buttonProps}\n />\n </div>\n </div>\n );\n};\n\nHelpScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n /**\n * To specify if the help screen is standalone or not.\n */\n standalone: PropTypes.bool,\n};\n\nexport default HelpScreen;\n","import React from \"react\";\n\nimport classnames from \"classnames\";\nimport withT from \"neetocommons/react-utils/withT\";\nimport { RightArrow } from \"neetoicons\";\nimport { Button, Typography } from \"neetoui\";\nimport PropTypes from \"prop-types\";\n\nimport \"./onboarding.scss\";\n\nconst WelcomeScreen = withT(\n ({ t, title, description, buttonProps, className = \"\" }) => (\n <div\n className={classnames(\"neeto-molecules-onboarding__wrapper\", className)}\n data-testid=\"onboarding-welcome-wrapper\"\n >\n <div className=\"mx-auto mb-6 w-full max-w-2xl space-y-2\">\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-title\"\n data-testid=\"onboarding-welcome-title\"\n style=\"h1\"\n >\n {title}\n </Typography>\n {description && (\n <Typography\n className=\"text-center\"\n data-cy=\"onboarding-welcome-description\"\n data-testid=\"onboarding-welcome-description\"\n lineHeight=\"normal\"\n style=\"body1\"\n >\n {description}\n </Typography>\n )}\n </div>\n <Button\n data-cy=\"onboarding-welcome-button\"\n data-testid=\"onboarding-welcome-button\"\n icon={RightArrow}\n label={t(\"neetoMolecules.onboarding.getStarted\")}\n {...buttonProps}\n />\n </div>\n )\n);\n\nWelcomeScreen.propTypes = {\n /**\n * To specify external classnames as overrides.\n */\n className: PropTypes.string,\n /**\n * Title of the welcome screen\n */\n title: PropTypes.string,\n /**\n * Description of the welcome screen\n */\n description: PropTypes.string,\n /**\n * Additional props that can be passed on to the button\n */\n buttonProps: PropTypes.object,\n};\n\nexport default WelcomeScreen;\n"],"names":["CompletedScreen","withT","_ref","t","title","description","children","buttonProps","_ref$className","className","React","createElement","classnames","Typography","style","lineHeight","isPresent","Button","_extends","label","propTypes","PropTypes","string","oneOfType","node","object","HelpScreen","_ref$standalone","standalone","_useTranslation","useTranslation","_useBreakpoints","useBreakpoints","isSize","component","appName","globalProps","alt","src","WelcomeScreen","icon","RightArrow"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAUA,IAAMA,eAAe,GAAGC,yBAAK,CAC3B,UAAAC,IAAA,EAAA;AAAA,EAAA,IAAGC,CAAC,GAAAD,IAAA,CAADC,CAAC;IAAEC,KAAK,GAAAF,IAAA,CAALE,KAAK;IAAEC,WAAW,GAAAH,IAAA,CAAXG,WAAW;IAAEC,QAAQ,GAAAJ,IAAA,CAARI,QAAQ;IAAEC,WAAW,GAAAL,IAAA,CAAXK,WAAW;IAAAC,cAAA,GAAAN,IAAA,CAAEO,SAAS;AAATA,IAAAA,SAAS,GAAAD,cAAA,KAAG,KAAA,CAAA,GAAA,EAAE,GAAAA,cAAA,CAAA;EAAA,oBAC7DE,yBAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEF,IAAAA,SAAS,EAAEG,8BAAU,CAAC,qCAAqC,EAAEH,SAAS,CAAE;IACxE,aAAY,EAAA,oCAAA;GAEZC,eAAAA,yBAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKF,IAAAA,SAAS,EAAC,yCAAA;AAAyC,GAAA,eACtDC,yBAAA,CAAAC,aAAA,CAACE,kBAAU,EAAA;AACTJ,IAAAA,SAAS,EAAC,aAAa;AACvB,IAAA,SAAA,EAAQ,kCAAkC;AAC1CK,IAAAA,KAAK,EAAC,IAAA;AAAI,GAAA,EACX,cAEW,CAAC,eACbJ,yBAAA,CAAAC,aAAA,CAACE,kBAAU,EAAA;AACTJ,IAAAA,SAAS,EAAC,aAAa;AACvB,IAAA,SAAA,EAAQ,kCAAkC;AAC1C,IAAA,aAAA,EAAY,kCAAkC;AAC9CK,IAAAA,KAAK,EAAC,IAAA;GAENJ,e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/Rename.js
CHANGED
package/dist/cjs/Rename.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Rename.js","sources":["../../src/components/Rename/utils.js","../../src/components/Rename/EditName.jsx","../../src/components/Rename/RenameMenu.jsx","../../src/components/Rename/ViewName.jsx","../../src/components/Rename/index.jsx"],"sourcesContent":["export const mergeRefs =\n (...refs) =>\n node =>\n refs.forEach(ref =>\n typeof ref === \"function\" ? ref(node) : (ref.current = node)\n );\n","import React from \"react\";\n\nimport { withEventTargetValue } from \"neetocommons/utils/general\";\nimport useHotkeys from \"neetohotkeys\";\nimport { Check, Close } from \"neetoicons\";\nimport { Button, Input } from \"neetoui\";\nimport { isEmpty } from \"ramda\";\n\nimport { mergeRefs } from \"./utils\";\n\nconst Editor = ({\n placeholder,\n allowEmptySubmission,\n name,\n isLoading,\n handleRename,\n submitButtonProps,\n handleClose,\n cancelButtonProps,\n setName,\n inputProps,\n editMode,\n}) => {\n const closeRef = useHotkeys(\"escape\", event => handleClose({ event }), {\n mode: \"scoped\",\n enabled: editMode,\n });\n\n const submitRef = useHotkeys(\n [\"command+return\", \"return\"],\n event => {\n if (isEmpty(name) && !allowEmptySubmission) return;\n handleRename(event, name);\n },\n { mode: \"scoped\", enabled: editMode }\n );\n\n return (\n <div className=\"relative flex min-w-0 max-w-full flex-grow\">\n <span className=\"neeto-molecules-rename__input-width-maker\">\n {name.replace(/\\s/g, \".\") || placeholder}\n </span>\n <Input\n {...{ placeholder }}\n autoFocus\n className=\"neeto-molecules-rename__input absolute\"\n data-cy=\"form-rename-text-field\"\n data-testid=\"neeto-molecules-name-input\"\n ref={mergeRefs(closeRef, submitRef)}\n value={name}\n suffix={\n <div className=\"flex items-center justify-end\">\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-submit-button\"\n data-testid=\"neeto-molecules-rename-button\"\n disabled={(!allowEmptySubmission && isEmpty(name)) || isLoading}\n icon={Check}\n loading={isLoading}\n style=\"text\"\n onClick={event => handleRename(event, name)}\n {...submitButtonProps}\n />\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-close-button\"\n data-testid=\"neeto-molecules-cancel-button\"\n disabled={isLoading}\n icon={Close}\n style=\"text\"\n onClick={event => handleClose({ event })}\n {...cancelButtonProps}\n />\n </div>\n }\n onChange={withEventTargetValue(setName)}\n onClick={event => event.stopPropagation()}\n {...inputProps}\n label={null}\n />\n </div>\n );\n};\n\nexport default Editor;\n","import React from \"react\";\n\nimport { isPresent } from \"neetocist\";\nimport { withT } from \"neetocommons/react-utils\";\n\nimport MoreDropdown from \"components/MoreDropdown\";\n\nconst RenameMenu = withT(\n ({\n t,\n handleRenameClick,\n disabled,\n dropdownItems,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n }) => (\n <MoreDropdown\n dropdownButtonProps={{\n \"data-testid\": \"neeto-molecules-menu-button\",\n ...dropdownButtonProps,\n }}\n dropdownProps={{\n position: \"bottom-start\",\n onClick: event => event.stopPropagation(),\n strategy: \"fixed\",\n appendTo: () => document.body,\n ...dropdownProps,\n }}\n menuItems={[\n {\n \"data-cy\": \"form-rename-button\",\n onClick: handleRenameClick,\n label: t(\"neetoMolecules.common.actions.rename\"),\n isVisible: !disabled,\n key: \"edit-name-menu\",\n },\n {\n \"data-cy\": \"form-clone-button\",\n onClick: onClone,\n label: t(\"neetoMolecules.common.actions.clone\"),\n isVisible: isPresent(onClone),\n key: \"clone-entity-menu\",\n },\n {\n \"data-cy\": \"form-archive-button\",\n onClick: onArchiveStatusToggle,\n label: isArchived\n ? t(\"neetoMolecules.common.actions.unArchive\")\n : t(\"neetoMolecules.common.actions.archive\"),\n isVisible: isPresent(onArchiveStatusToggle),\n key: \"archive-entity-menu\",\n },\n {\n \"data-cy\": \"form-enable-button\",\n onClick: onDisableStatusToggle,\n label: isDisabled\n ? t(\"neetoMolecules.common.actions.enable\")\n : t(\"neetoMolecules.common.actions.disable\"),\n isVisible: isPresent(onDisableStatusToggle),\n key: \"enable-entity-menu\",\n },\n {\n \"data-cy\": \"form-delete-button\",\n onClick: onDelete,\n label: t(\"neetoMolecules.common.actions.delete\"),\n isVisible: isPresent(onDelete),\n key: \"delete-entity-menu\",\n },\n ...dropdownItems,\n ]}\n />\n )\n);\n\nexport default RenameMenu;\n","import React from \"react\";\n\nimport classNames from \"classnames\";\nimport { isNotEmpty, isPresent } from \"neetocist\";\nimport { Typography } from \"neetoui\";\n\nimport RenameMenu from \"./RenameMenu\";\n\nconst ViewName = ({\n disabled,\n textProps,\n formatText,\n dropdownItems,\n hideMenu,\n handleRenameClick,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n name,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n}) => {\n const isDefaultMenuCallbacksPresent =\n isPresent(onArchiveStatusToggle) ||\n isPresent(onDisableStatusToggle) ||\n isPresent(onDelete) ||\n isPresent(onClone);\n\n const isMenuVisible =\n !hideMenu &&\n (isNotEmpty(dropdownItems) || !disabled || isDefaultMenuCallbacksPresent);\n\n return (\n <>\n <Typography\n component=\"p\"\n data-cy=\"form-title\"\n data-testid=\"neeto-molecules-value-display\"\n style=\"body2\"\n className={classNames(\n \"neeto-molecules-rename__text neeto-molecules-rename__display-text w-full truncate\",\n {\n \"cursor-pointer\": !disabled,\n \"pointer-events-none cursor-text\": disabled,\n }\n )}\n onClick={handleRenameClick}\n {...textProps}\n >\n {typeof formatText === \"function\" ? formatText(name) : name}\n </Typography>\n {isMenuVisible && (\n <RenameMenu\n {...{\n disabled,\n dropdownButtonProps,\n dropdownItems,\n dropdownProps,\n handleRenameClick,\n isArchived,\n isDisabled,\n onArchiveStatusToggle,\n onClone,\n onDelete,\n onDisableStatusToggle,\n }}\n />\n )}\n </>\n );\n};\n\nexport default ViewName;\n","import React, { useState, useRef, useMemo } from \"react\";\n\nimport classnames from \"classnames\";\nimport { isNotEmpty, notEquals } from \"neetocist\";\nimport useOnClickOutside from \"neetocommons/react-utils/useOnClickOutside\";\nimport useStateWithDependency from \"neetocommons/react-utils/useStateWithDependency\";\nimport PropTypes from \"prop-types\";\nimport { isEmpty } from \"ramda\";\n\nimport Breadcrumbs from \"components/Breadcrumbs\";\n\nimport EditName from \"./EditName\";\nimport \"./rename.scss\";\nimport ViewName from \"./ViewName\";\n\nconst Rename = ({\n value,\n onRename,\n onClone,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onDelete,\n isArchived,\n isDisabled,\n isOpen = false,\n isLoading = false,\n placeholder = \"\",\n hideMenu = false,\n disabled = false,\n dropdownItems = [],\n breadcrumbs = [],\n textProps = {},\n inputProps = {},\n submitButtonProps = {},\n cancelButtonProps = {},\n className = \"\",\n allowEmptySubmission = false,\n defaultName = \"\",\n formatText,\n dropdownButtonProps = {},\n dropdownProps = {},\n}) => {\n const [name, setName] = useStateWithDependency(value ?? \"\");\n const [editMode, setEditMode] = useState(isOpen);\n const renameRef = useRef(null);\n\n const initialName = useMemo(() => name, [editMode]);\n\n useOnClickOutside(\n renameRef,\n () =>\n editMode &&\n handleClose({ saveOnOutsideClick: notEquals(name, initialName) })\n );\n\n const handleRename = (event, name) => {\n event?.stopPropagation();\n const newName = allowEmptySubmission && isEmpty(name) ? defaultName : name;\n setName(newName);\n onRename?.(newName);\n setEditMode(false);\n };\n\n const handleClose = ({ event = null, saveOnOutsideClick = false }) => {\n event?.stopPropagation();\n saveOnOutsideClick ? handleRename(event, name) : setName(value);\n setEditMode(false);\n };\n\n const handleRenameClick = event => {\n event.stopPropagation();\n !disabled && setEditMode(true);\n };\n\n const editNameProps = {\n allowEmptySubmission,\n cancelButtonProps,\n handleClose,\n handleRename,\n inputProps,\n isLoading,\n name,\n placeholder,\n setName,\n submitButtonProps,\n editMode,\n };\n\n const viewNameProps = {\n disabled,\n dropdownItems,\n formatText,\n handleRenameClick,\n hideMenu,\n name,\n isArchived,\n onArchiveStatusToggle,\n isDisabled,\n onDisableStatusToggle,\n onClone,\n onDelete,\n textProps,\n dropdownButtonProps,\n dropdownProps,\n };\n\n return (\n <div\n ref={renameRef}\n className={classnames(\n \"neeto-molecules-rename flex min-w-0 max-w-md flex-col items-start md:flex-row md:items-center\",\n className\n )}\n >\n {isNotEmpty(breadcrumbs) && (\n <Breadcrumbs\n {...{ breadcrumbs }}\n hasTrailingSeparator\n className=\"neeto-molecules-rename-breadcrumbs\"\n />\n )}\n <div className=\"relative flex max-w-full items-center gap-x-2\">\n {editMode ? (\n <EditName {...editNameProps} />\n ) : (\n <ViewName {...viewNameProps} />\n )}\n </div>\n </div>\n );\n};\n\nRename.propTypes = {\n /**\n * To provide additional classes to the component.\n */\n className: PropTypes.string,\n /**\n * To allow empty submission.\n */\n allowEmptySubmission: PropTypes.bool,\n /**\n * Default value to be used on empty submission.\n */\n defaultName: PropTypes.string,\n /**\n * To specify the text to be displayed in the component.\n */\n value: PropTypes.string,\n /**\n * To specify the function to be triggered when renamed.\n */\n onRename: PropTypes.func,\n /**\n * To specify the function to be triggered when Clone menu is clicked. The menu will be hidden if this prop is not set.\n */\n onClone: PropTypes.func,\n /**\n * To specify the function to be triggered when Archive menu is clicked. The menu will be hidden if this prop is not set.\n */\n onArchiveStatusToggle: PropTypes.func,\n /**\n * To specify the function to be triggered when Enable/Disable menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDisableStatusToggle: PropTypes.func,\n /**\n * To specify whether the entity is archived or not. The text in the menu will be changed based on this to Archive or Unarchive.\n */\n isArchived: PropTypes.bool,\n /**\n * To specify whether the entity is disabled or not. The text in the menu will be changed based on this to Enable or Disable.\n */\n isDisabled: PropTypes.bool,\n /**\n * To specify the function to be triggered when Delete menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDelete: PropTypes.func,\n /**\n * To specify whether edit mode is enabled or not.\n */\n isOpen: PropTypes.bool,\n /**\n * To specify whether the edit buttons are in loading state or not.\n */\n isLoading: PropTypes.bool,\n /**\n * To specify the placeholder for the input component in edit mode.\n */\n placeholder: PropTypes.string,\n /**\n * To specify whether the dropdown menu should be hidden or not.\n */\n hideMenu: PropTypes.bool,\n /**\n * To specify whether the rename option in dropdown should be enabled. If it is the only option in dropdown, the menu will be hidden.\n */\n disabled: PropTypes.bool,\n /**\n * To specify additional items for the dropdown menu.\n */\n dropdownItems: PropTypes.array,\n /**\n * To specify the breadcrumbs if used in the title of `Header` component.\n */\n breadcrumbs: PropTypes.arrayOf(\n PropTypes.shape({\n text: PropTypes.string,\n link: PropTypes.string,\n })\n ),\n /**\n * To override the properties of the Typography component that displays the `value`.\n */\n textProps: PropTypes.object,\n /**\n * To override the properties of the Input component in edit mode.\n */\n inputProps: PropTypes.object,\n /**\n * To format the value to display when not in edit mode.\n */\n formatText: PropTypes.func,\n /**\n * To override the properties of the submit button.\n */\n submitButtonProps: PropTypes.object,\n /**\n * To override the properties of the cancel button.\n */\n cancelButtonProps: PropTypes.object,\n};\n\nexport default Rename;\n"],"names":["mergeRefs","_len","arguments","length","refs","Array","_key","node","forEach","ref","current","Editor","_ref","placeholder","allowEmptySubmission","name","isLoading","handleRename","submitButtonProps","handleClose","cancelButtonProps","setName","inputProps","editMode","closeRef","useHotkeys","event","mode","enabled","submitRef","isEmpty","React","createElement","className","replace","Input","_extends","autoFocus","value","suffix","Button","disabled","icon","Check","loading","style","onClick","Close","onChange","withEventTargetValue","stopPropagation","label","RenameMenu","withT","t","handleRenameClick","dropdownItems","onArchiveStatusToggle","onDisableStatusToggle","onClone","onDelete","isArchived","isDisabled","dropdownButtonProps","dropdownProps","MoreDropdown","_objectSpread","position","strategy","appendTo","document","body","menuItems","isVisible","key","isPresent","concat","_toConsumableArray","ViewName","textProps","formatText","hideMenu","isDefaultMenuCallbacksPresent","isMenuVisible","isNotEmpty","Fragment","Typography","component","classNames","Rename","onRename","_ref$isOpen","isOpen","_ref$isLoading","_ref$placeholder","_ref$hideMenu","_ref$disabled","_ref$dropdownItems","_ref$breadcrumbs","breadcrumbs","_ref$textProps","_ref$inputProps","_ref$submitButtonProp","_ref$cancelButtonProp","_ref$className","_ref$allowEmptySubmis","_ref$defaultName","defaultName","_ref$dropdownButtonPr","_ref$dropdownProps","_useStateWithDependen","useStateWithDependency","_useStateWithDependen2","_slicedToArray","_useState","useState","_useState2","setEditMode","renameRef","useRef","initialName","useMemo","useOnClickOutside","saveOnOutsideClick","notEquals","newName","_ref2","_ref2$event","_ref2$saveOnOutsideCl","editNameProps","viewNameProps","classnames","Breadcrumbs","hasTrailingSeparator","EditName"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAO,IAAMA,SAAS,GACpB,SADWA,SAASA,GAAA;AAAA,EAAA,KAAA,IAAAC,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAChBC,IAAI,GAAAC,IAAAA,KAAA,CAAAJ,IAAA,GAAAK,IAAA,GAAA,CAAA,EAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA,EAAA,EAAA;AAAJF,IAAAA,IAAI,CAAAE,IAAA,CAAAJ,GAAAA,SAAA,CAAAI,IAAA,CAAA,CAAA;AAAA,GAAA;AAAA,EAAA,OACR,UAAAC,IAAI,EAAA;AAAA,IAAA,OACFH,IAAI,CAACI,OAAO,CAAC,UAAAC,GAAG,EAAA;AAAA,MAAA,OACd,OAAOA,GAAG,KAAK,UAAU,GAAGA,GAAG,CAACF,IAAI,CAAC,GAAIE,GAAG,CAACC,OAAO,GAAGH,IAAK,CAAA;AAAA,KAC9D,CAAC,CAAA;AAAA,GAAA,CAAA;AAAA,CAAA;;ACKL,IAAMI,MAAM,GAAG,SAATA,MAAMA,CAAAC,IAAA,EAYN;AAAA,EAAA,IAXJC,WAAW,GAAAD,IAAA,CAAXC,WAAW;IACXC,oBAAoB,GAAAF,IAAA,CAApBE,oBAAoB;IACpBC,IAAI,GAAAH,IAAA,CAAJG,IAAI;IACJC,SAAS,GAAAJ,IAAA,CAATI,SAAS;IACTC,YAAY,GAAAL,IAAA,CAAZK,YAAY;IACZC,i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,QAAQ,EAAKoD,aAAgB,CAE7B,CACF,CAAC,CAAA;AAEV;;;;"}
|
|
1
|
+
{"version":3,"file":"Rename.js","sources":["../../src/components/Rename/utils.js","../../src/components/Rename/EditName.jsx","../../src/components/Rename/RenameMenu.jsx","../../src/components/Rename/ViewName.jsx","../../src/components/Rename/index.jsx"],"sourcesContent":["export const mergeRefs =\n (...refs) =>\n node =>\n refs.forEach(ref =>\n typeof ref === \"function\" ? ref(node) : (ref.current = node)\n );\n","import React from \"react\";\n\nimport { withEventTargetValue } from \"neetocommons/utils/general\";\nimport useHotkeys from \"neetohotkeys\";\nimport { Check, Close } from \"neetoicons\";\nimport { Button, Input } from \"neetoui\";\nimport { isEmpty } from \"ramda\";\n\nimport { mergeRefs } from \"./utils\";\n\nconst Editor = ({\n placeholder,\n allowEmptySubmission,\n name,\n isLoading,\n handleRename,\n submitButtonProps,\n handleClose,\n cancelButtonProps,\n setName,\n inputProps,\n editMode,\n}) => {\n const closeRef = useHotkeys(\"escape\", event => handleClose({ event }), {\n mode: \"scoped\",\n enabled: editMode,\n });\n\n const submitRef = useHotkeys(\n [\"command+return\", \"return\"],\n event => {\n if (isEmpty(name) && !allowEmptySubmission) return;\n handleRename(event, name);\n },\n { mode: \"scoped\", enabled: editMode }\n );\n\n return (\n <div className=\"relative flex min-w-0 max-w-full flex-grow\">\n <span className=\"neeto-molecules-rename__input-width-maker\">\n {name.replace(/\\s/g, \".\") || placeholder}\n </span>\n <Input\n {...{ placeholder }}\n autoFocus\n className=\"neeto-molecules-rename__input absolute\"\n data-cy=\"form-rename-text-field\"\n data-testid=\"neeto-molecules-name-input\"\n ref={mergeRefs(closeRef, submitRef)}\n value={name}\n suffix={\n <div className=\"flex items-center justify-end\">\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-submit-button\"\n data-testid=\"neeto-molecules-rename-button\"\n disabled={(!allowEmptySubmission && isEmpty(name)) || isLoading}\n icon={Check}\n loading={isLoading}\n style=\"text\"\n onClick={event => handleRename(event, name)}\n {...submitButtonProps}\n />\n <Button\n className=\"neeto-ui-rounded-none\"\n data-cy=\"form-rename-close-button\"\n data-testid=\"neeto-molecules-cancel-button\"\n disabled={isLoading}\n icon={Close}\n style=\"text\"\n onClick={event => handleClose({ event })}\n {...cancelButtonProps}\n />\n </div>\n }\n onChange={withEventTargetValue(setName)}\n onClick={event => event.stopPropagation()}\n {...inputProps}\n label={null}\n />\n </div>\n );\n};\n\nexport default Editor;\n","import React from \"react\";\n\nimport { isPresent } from \"neetocist\";\nimport { withT } from \"neetocommons/react-utils\";\n\nimport MoreDropdown from \"components/MoreDropdown\";\n\nconst RenameMenu = withT(\n ({\n t,\n handleRenameClick,\n disabled,\n dropdownItems,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n }) => (\n <MoreDropdown\n dropdownButtonProps={{\n \"data-testid\": \"neeto-molecules-menu-button\",\n ...dropdownButtonProps,\n }}\n dropdownProps={{\n position: \"bottom-start\",\n onClick: event => event.stopPropagation(),\n strategy: \"fixed\",\n appendTo: () => document.body,\n zIndex: \"99999\",\n ...dropdownProps,\n }}\n menuItems={[\n {\n \"data-cy\": \"form-rename-button\",\n onClick: handleRenameClick,\n label: t(\"neetoMolecules.common.actions.rename\"),\n isVisible: !disabled,\n key: \"edit-name-menu\",\n },\n {\n \"data-cy\": \"form-clone-button\",\n onClick: onClone,\n label: t(\"neetoMolecules.common.actions.clone\"),\n isVisible: isPresent(onClone),\n key: \"clone-entity-menu\",\n },\n {\n \"data-cy\": \"form-archive-button\",\n onClick: onArchiveStatusToggle,\n label: isArchived\n ? t(\"neetoMolecules.common.actions.unArchive\")\n : t(\"neetoMolecules.common.actions.archive\"),\n isVisible: isPresent(onArchiveStatusToggle),\n key: \"archive-entity-menu\",\n },\n {\n \"data-cy\": \"form-enable-button\",\n onClick: onDisableStatusToggle,\n label: isDisabled\n ? t(\"neetoMolecules.common.actions.enable\")\n : t(\"neetoMolecules.common.actions.disable\"),\n isVisible: isPresent(onDisableStatusToggle),\n key: \"enable-entity-menu\",\n },\n {\n \"data-cy\": \"form-delete-button\",\n onClick: onDelete,\n label: t(\"neetoMolecules.common.actions.delete\"),\n isVisible: isPresent(onDelete),\n key: \"delete-entity-menu\",\n },\n ...dropdownItems,\n ]}\n />\n )\n);\n\nexport default RenameMenu;\n","import React from \"react\";\n\nimport classNames from \"classnames\";\nimport { isNotEmpty, isPresent } from \"neetocist\";\nimport { Typography } from \"neetoui\";\n\nimport RenameMenu from \"./RenameMenu\";\n\nconst ViewName = ({\n disabled,\n textProps,\n formatText,\n dropdownItems,\n hideMenu,\n handleRenameClick,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onClone,\n onDelete,\n name,\n isArchived,\n isDisabled,\n dropdownButtonProps,\n dropdownProps,\n}) => {\n const isDefaultMenuCallbacksPresent =\n isPresent(onArchiveStatusToggle) ||\n isPresent(onDisableStatusToggle) ||\n isPresent(onDelete) ||\n isPresent(onClone);\n\n const isMenuVisible =\n !hideMenu &&\n (isNotEmpty(dropdownItems) || !disabled || isDefaultMenuCallbacksPresent);\n\n return (\n <>\n <Typography\n component=\"p\"\n data-cy=\"form-title\"\n data-testid=\"neeto-molecules-value-display\"\n style=\"body2\"\n className={classNames(\n \"neeto-molecules-rename__text neeto-molecules-rename__display-text w-full truncate\",\n {\n \"cursor-pointer\": !disabled,\n \"pointer-events-none cursor-text\": disabled,\n }\n )}\n onClick={handleRenameClick}\n {...textProps}\n >\n {typeof formatText === \"function\" ? formatText(name) : name}\n </Typography>\n {isMenuVisible && (\n <RenameMenu\n {...{\n disabled,\n dropdownButtonProps,\n dropdownItems,\n dropdownProps,\n handleRenameClick,\n isArchived,\n isDisabled,\n onArchiveStatusToggle,\n onClone,\n onDelete,\n onDisableStatusToggle,\n }}\n />\n )}\n </>\n );\n};\n\nexport default ViewName;\n","import React, { useState, useRef, useMemo } from \"react\";\n\nimport classnames from \"classnames\";\nimport { isNotEmpty, notEquals } from \"neetocist\";\nimport useOnClickOutside from \"neetocommons/react-utils/useOnClickOutside\";\nimport useStateWithDependency from \"neetocommons/react-utils/useStateWithDependency\";\nimport PropTypes from \"prop-types\";\nimport { isEmpty } from \"ramda\";\n\nimport Breadcrumbs from \"components/Breadcrumbs\";\n\nimport EditName from \"./EditName\";\nimport \"./rename.scss\";\nimport ViewName from \"./ViewName\";\n\nconst Rename = ({\n value,\n onRename,\n onClone,\n onArchiveStatusToggle,\n onDisableStatusToggle,\n onDelete,\n isArchived,\n isDisabled,\n isOpen = false,\n isLoading = false,\n placeholder = \"\",\n hideMenu = false,\n disabled = false,\n dropdownItems = [],\n breadcrumbs = [],\n textProps = {},\n inputProps = {},\n submitButtonProps = {},\n cancelButtonProps = {},\n className = \"\",\n allowEmptySubmission = false,\n defaultName = \"\",\n formatText,\n dropdownButtonProps = {},\n dropdownProps = {},\n}) => {\n const [name, setName] = useStateWithDependency(value ?? \"\");\n const [editMode, setEditMode] = useState(isOpen);\n const renameRef = useRef(null);\n\n const initialName = useMemo(() => name, [editMode]);\n\n useOnClickOutside(\n renameRef,\n () =>\n editMode &&\n handleClose({ saveOnOutsideClick: notEquals(name, initialName) })\n );\n\n const handleRename = (event, name) => {\n event?.stopPropagation();\n const newName = allowEmptySubmission && isEmpty(name) ? defaultName : name;\n setName(newName);\n onRename?.(newName);\n setEditMode(false);\n };\n\n const handleClose = ({ event = null, saveOnOutsideClick = false }) => {\n event?.stopPropagation();\n saveOnOutsideClick ? handleRename(event, name) : setName(value);\n setEditMode(false);\n };\n\n const handleRenameClick = event => {\n event.stopPropagation();\n !disabled && setEditMode(true);\n };\n\n const editNameProps = {\n allowEmptySubmission,\n cancelButtonProps,\n handleClose,\n handleRename,\n inputProps,\n isLoading,\n name,\n placeholder,\n setName,\n submitButtonProps,\n editMode,\n };\n\n const viewNameProps = {\n disabled,\n dropdownItems,\n formatText,\n handleRenameClick,\n hideMenu,\n name,\n isArchived,\n onArchiveStatusToggle,\n isDisabled,\n onDisableStatusToggle,\n onClone,\n onDelete,\n textProps,\n dropdownButtonProps,\n dropdownProps,\n };\n\n return (\n <div\n ref={renameRef}\n className={classnames(\n \"neeto-molecules-rename flex min-w-0 max-w-md flex-col items-start md:flex-row md:items-center\",\n className\n )}\n >\n {isNotEmpty(breadcrumbs) && (\n <Breadcrumbs\n {...{ breadcrumbs }}\n hasTrailingSeparator\n className=\"neeto-molecules-rename-breadcrumbs\"\n />\n )}\n <div className=\"relative flex max-w-full items-center gap-x-2\">\n {editMode ? (\n <EditName {...editNameProps} />\n ) : (\n <ViewName {...viewNameProps} />\n )}\n </div>\n </div>\n );\n};\n\nRename.propTypes = {\n /**\n * To provide additional classes to the component.\n */\n className: PropTypes.string,\n /**\n * To allow empty submission.\n */\n allowEmptySubmission: PropTypes.bool,\n /**\n * Default value to be used on empty submission.\n */\n defaultName: PropTypes.string,\n /**\n * To specify the text to be displayed in the component.\n */\n value: PropTypes.string,\n /**\n * To specify the function to be triggered when renamed.\n */\n onRename: PropTypes.func,\n /**\n * To specify the function to be triggered when Clone menu is clicked. The menu will be hidden if this prop is not set.\n */\n onClone: PropTypes.func,\n /**\n * To specify the function to be triggered when Archive menu is clicked. The menu will be hidden if this prop is not set.\n */\n onArchiveStatusToggle: PropTypes.func,\n /**\n * To specify the function to be triggered when Enable/Disable menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDisableStatusToggle: PropTypes.func,\n /**\n * To specify whether the entity is archived or not. The text in the menu will be changed based on this to Archive or Unarchive.\n */\n isArchived: PropTypes.bool,\n /**\n * To specify whether the entity is disabled or not. The text in the menu will be changed based on this to Enable or Disable.\n */\n isDisabled: PropTypes.bool,\n /**\n * To specify the function to be triggered when Delete menu is clicked. The menu will be hidden if this prop is not set.\n */\n onDelete: PropTypes.func,\n /**\n * To specify whether edit mode is enabled or not.\n */\n isOpen: PropTypes.bool,\n /**\n * To specify whether the edit buttons are in loading state or not.\n */\n isLoading: PropTypes.bool,\n /**\n * To specify the placeholder for the input component in edit mode.\n */\n placeholder: PropTypes.string,\n /**\n * To specify whether the dropdown menu should be hidden or not.\n */\n hideMenu: PropTypes.bool,\n /**\n * To specify whether the rename option in dropdown should be enabled. If it is the only option in dropdown, the menu will be hidden.\n */\n disabled: PropTypes.bool,\n /**\n * To specify additional items for the dropdown menu.\n */\n dropdownItems: PropTypes.array,\n /**\n * To specify the breadcrumbs if used in the title of `Header` component.\n */\n breadcrumbs: PropTypes.arrayOf(\n PropTypes.shape({\n text: PropTypes.string,\n link: PropTypes.string,\n })\n ),\n /**\n * To override the properties of the Typography component that displays the `value`.\n */\n textProps: PropTypes.object,\n /**\n * To override the properties of the Input component in edit mode.\n */\n inputProps: PropTypes.object,\n /**\n * To format the value to display when not in edit mode.\n */\n formatText: PropTypes.func,\n /**\n * To override the properties of the submit button.\n */\n submitButtonProps: PropTypes.object,\n /**\n * To override the properties of the cancel button.\n */\n cancelButtonProps: PropTypes.object,\n};\n\nexport default Rename;\n"],"names":["mergeRefs","_len","arguments","length","refs","Array","_key","node","forEach","ref","current","Editor","_ref","placeholder","allowEmptySubmission","name","isLoading","handleRename","submitButtonProps","handleClose","cancelButtonProps","setName","inputProps","editMode","closeRef","useHotkeys","event","mode","enabled","submitRef","isEmpty","React","createElement","className","replace","Input","_extends","autoFocus","value","suffix","Button","disabled","icon","Check","loading","style","onClick","Close","onChange","withEventTargetValue","stopPropagation","label","RenameMenu","withT","t","handleRenameClick","dropdownItems","onArchiveStatusToggle","onDisableStatusToggle","onClone","onDelete","isArchived","isDisabled","dropdownButtonProps","dropdownProps","MoreDropdown","_objectSpread","position","strategy","appendTo","document","body","zIndex","menuItems","isVisible","key","isPresent","concat","_toConsumableArray","ViewName","textProps","formatText","hideMenu","isDefaultMenuCallbacksPresent","isMenuVisible","isNotEmpty","Fragment","Typography","component","classNames","Rename","onRename","_ref$isOpen","isOpen","_ref$isLoading","_ref$placeholder","_ref$hideMenu","_ref$disabled","_ref$dropdownItems","_ref$breadcrumbs","breadcrumbs","_ref$textProps","_ref$inputProps","_ref$submitButtonProp","_ref$cancelButtonProp","_ref$className","_ref$allowEmptySubmis","_ref$defaultName","defaultName","_ref$dropdownButtonPr","_ref$dropdownProps","_useStateWithDependen","useStateWithDependency","_useStateWithDependen2","_slicedToArray","_useState","useState","_useState2","setEditMode","renameRef","useRef","initialName","useMemo","useOnClickOutside","saveOnOutsideClick","notEquals","newName","_ref2","_ref2$event","_ref2$saveOnOutsideCl","editNameProps","viewNameProps","classnames","Breadcrumbs","hasTrailingSeparator","EditName"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAO,IAAMA,SAAS,GACpB,SADWA,SAASA,GAAA;AAAA,EAAA,KAAA,IAAAC,IAAA,GAAAC,SAAA,CAAAC,MAAA,EAChBC,IAAI,GAAAC,IAAAA,KAAA,CAAAJ,IAAA,GAAAK,IAAA,GAAA,CAAA,EAAAA,IAAA,GAAAL,IAAA,EAAAK,IAAA,EAAA,EAAA;AAAJF,IAAAA,IAAI,CAAAE,IAAA,CAAAJ,GAAAA,SAAA,CAAAI,IAAA,CAAA,CAAA;AAAA,GAAA;AAAA,EAAA,OACR,UAAAC,IAAI,EAAA;AAAA,IAAA,OACFH,IAAI,CAACI,OAAO,CAAC,UAAAC,GAAG,EAAA;AAAA,MAAA,OACd,OAAOA,GAAG,KAAK,UAAU,GAAGA,GAAG,CAACF,IAAI,CAAC,GAAIE,GAAG,CAACC,OAAO,GAAGH,IAAK,CAAA;AAAA,KAC9D,CAAC,CAAA;AAAA,GAAA,CAAA;AAAA,CAAA;;ACKL,IAAMI,MAAM,GAAG,SAATA,MAAMA,CAAAC,IAAA,EAYN;AAAA,EAAA,IAXJC,WAAW,GAAAD,IAAA,CAAXC,WAAW;IACXC,oBAAoB,GAAAF,IAAA,CAApBE,oBAAoB;IACpBC,IAAI,GAAAH,IAAA,CAAJG,IAAI;IACJC,SAAS,GAAAJ,IAAA,CAATI,SAAS;IACTC,YAAY,GAAAL,IAAA,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L,aAAgB,CAAC,gBAE/BnG,yBAAA,CAAAC,aAAA,CAAC+C,QAAQ,EAAKoD,aAAgB,CAE7B,CACF,CAAC,CAAA;AAEV;;;;"}
|
package/dist/cjs/Sidebar.js
CHANGED
|
@@ -11,7 +11,7 @@ var neetoui = require('@bigbinary/neetoui');
|
|
|
11
11
|
var ramda = require('ramda');
|
|
12
12
|
var reactI18next = require('react-i18next');
|
|
13
13
|
var reactRouterDom = require('react-router-dom');
|
|
14
|
-
var Chevron = require('./Chevron-
|
|
14
|
+
var Chevron = require('./Chevron-166f3f91.js');
|
|
15
15
|
var useFetchNeetoApps = require('@bigbinary/neeto-commons-frontend/react-utils/useFetchNeetoApps');
|
|
16
16
|
var ProductTypefaceLogos = require('@bigbinary/neeto-icons/typeface-logos');
|
|
17
17
|
var _extends = require('./extends-1b35a664.js');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bigbinary/neeto-molecules",
|
|
3
|
-
"version": "1.15.
|
|
3
|
+
"version": "1.15.44",
|
|
4
4
|
"description": "A package of reusable molecular components for neeto products.",
|
|
5
5
|
"repository": "git@github.com:bigbinary/neeto-molecules.git",
|
|
6
6
|
"author": "Amaljith K <amaljith.k@bigbinary.com>",
|
package/src/translations/en.json
CHANGED
|
@@ -725,8 +725,10 @@
|
|
|
725
725
|
"startUsing": "Start using",
|
|
726
726
|
"helpScreen": {
|
|
727
727
|
"title": "Finding help articles & Chat support",
|
|
728
|
+
"welcomeToTitle": "Welcome to {{appName, anyCase}}",
|
|
728
729
|
"description": "If you have any questions at any time hover your profile picture at the bottom left corner of your screen. Now you can click on \"Help articles\" or click on \"Chat with support\".",
|
|
729
|
-
"continueButton": "Continue"
|
|
730
|
+
"continueButton": "Continue",
|
|
731
|
+
"startUsingButton": "Start using {{appName, anyCase}}"
|
|
730
732
|
}
|
|
731
733
|
},
|
|
732
734
|
"moreDropdown": {
|