Просмотр исходного кода

Fix "Copy to clipboard" anchor link

Koki Oyatsu 5 лет назад
Родитель
Сommit
fb8e599d2b
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      src/client/js/components/Page/CopyDropdown.jsx

+ 2 - 2
src/client/js/components/Page/CopyDropdown.jsx

@@ -62,7 +62,7 @@ class CopyDropdown extends React.Component {
 
   generatePagePathUrl() {
     const { origin } = window.location;
-    return `${origin}${this.generatePagePathWithParams()}`;
+    return `${origin}${encodeURI(this.generatePagePathWithParams())}`;
   }
 
   generatePermalink() {
@@ -75,7 +75,7 @@ class CopyDropdown extends React.Component {
       return decodeURI(`${origin}/share/${pageId}`);
     }
 
-    return decodeURI(`${origin}/${pageId}${this.uriParams}`);
+    return decodeURI(`${origin}/${pageId}`) + this.uriParams;
   }
 
   generateMarkdownLink() {