diy-template-components 2.0.50 → 2.0.51

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/build/index.js CHANGED
@@ -1092,7 +1092,8 @@ function OptionList({
1092
1092
  function checkIsActiveTab(slug = "") {
1093
1093
  if (typeof window !== "undefined") {
1094
1094
  const pathname = window.location.pathname;
1095
- if (slug && pathname.includes(slug)) {
1095
+ const slugFromPathname = pathname?.split('/')[1];
1096
+ if (slug && slugFromPathname.includes(slug)) {
1096
1097
  return true;
1097
1098
  } else {
1098
1099
  return false;