瀏覽代碼

add slash

ryohek 6 年之前
父節點
當前提交
b46c745bb6
共有 1 個文件被更改,包括 4 次插入1 次删除
  1. 4 1
      src/client/js/components/Page/CopyDropdown.jsx

+ 4 - 1
src/client/js/components/Page/CopyDropdown.jsx

@@ -54,7 +54,10 @@ class CopyDropdown extends React.Component {
   }
 
   generatePagePathWithParams() {
-    const { pagePath } = this.props;
+    const { pagePath, isShareLinkMode } = this.props;
+    if (isShareLinkMode) {
+      return decodeURI(`/${pagePath}`);
+    }
     return decodeURI(`${pagePath}${this.uriParams}`);
   }