@antv/dumi-theme-antv 0.3.0 → 0.3.1

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.
@@ -76,7 +76,8 @@ export var ExampleSider = function ExampleSider(props) {
76
76
  useEffect(function () {
77
77
  var targetExample = currentDemo.targetExample,
78
78
  targetTopic = currentDemo.targetTopic;
79
- setOpenKeys(["TOPIC-".concat(targetTopic === null || targetTopic === void 0 ? void 0 : targetTopic.id), "EXAMPLE-".concat(targetExample === null || targetExample === void 0 ? void 0 : targetExample.id)]);
79
+ var keys = ["TOPIC-".concat(targetTopic === null || targetTopic === void 0 ? void 0 : targetTopic.id), "EXAMPLE-".concat(targetTopic.id, "-").concat(targetExample === null || targetExample === void 0 ? void 0 : targetExample.id)];
80
+ setOpenKeys(keys);
80
81
  }, [currentDemo]); // 初始化滚动到中间
81
82
 
82
83
  useEffect(function () {
@@ -55,7 +55,8 @@ export function getNavigateUrl(pathname, first, siderbarMenu) {
55
55
  }
56
56
 
57
57
  if (siderbarMenu.every(function (item) {
58
- return ![item, "".concat(item, "/")].includes(pathname);
58
+ var itemLowerCase = "".concat(item).toLowerCase();
59
+ return ![itemLowerCase, "".concat(itemLowerCase, "/")].includes(pathname.toLowerCase());
59
60
  })) {
60
61
  return first;
61
62
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@antv/dumi-theme-antv",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "AntV website theme based on dumi2.",
5
5
  "types": "dist/types.d.ts",
6
6
  "scripts": {