"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.useIsExpanded=void 0;const react_1=require("react"),react_router_dom_1=require("react-router-dom"),utils_1=require("../../utils");function useIsExpanded({item:e,routingBasePath:t}){const r=(0,react_router_dom_1.useLocation)(),o=(0,react_1.useMemo)((()=>decodeURIComponent((0,utils_1.normalizePath)(r.pathname.replace(t,"")))),[r.pathname,t]);if("tag"!==e.type)return!1;return[e.href,...e.items.map((e=>e.href))].some((e=>[e,decodeURIComponent(e)].includes(o)))}exports.useIsExpanded=useIsExpanded;
//# sourceMappingURL=useIsExpanded.js.map