Преглед изворни кода

warning when not creatable

Shun Miyazawa пре 4 година
родитељ
комит
34987f69c5

+ 1 - 0
packages/app/resource/locales/en_US/translation.json

@@ -168,6 +168,7 @@
   "duplicated_path":"duplicated_path",
   "Link sharing is disabled": "Link sharing is disabled",
   "successfully_saved_the_page": "Successfully saved the page",
+  "you_can_not_create_page_with_this_name": "You can not create page with this name",
   "personal_dropdown": {
     "home": "Home",
     "settings": "Settings",

+ 1 - 0
packages/app/resource/locales/ja_JP/translation.json

@@ -170,6 +170,7 @@
   "duplicated_path":"重複したパス",
   "Link sharing is disabled": "リンクのシェアは無効化されています",
   "successfully_saved_the_page": "ページが正常に保存されました",
+  "you_can_not_create_page_with_this_name": "この名前でページを作成することはできません",
   "personal_dropdown": {
     "home": "ホーム",
     "settings": "設定",

+ 1 - 0
packages/app/resource/locales/zh_CN/translation.json

@@ -176,6 +176,7 @@
   "duplicated_path":"duplicated_path",
   "Link sharing is disabled": "你不允许分享该链接",
   "successfully_saved_the_page": "成功地保存了该页面",
+  "you_can_not_create_page_with_this_name": "您无法使用此名称创建页面",
 	"form_validation": {
 		"error_message": "有些值不正确",
 		"required": "%s 是必需的",

+ 1 - 0
packages/app/src/components/Sidebar/PageTree/Item.tsx

@@ -267,6 +267,7 @@ const Item: FC<ItemProps> = (props: ItemProps) => {
     const isCreatable = pagePathUtils.isCreatablePage(newPagePath);
 
     if (!isCreatable) {
+      toastWarning(t('you_can_not_create_page_with_this_name'));
       return;
     }