Skip to content

Commit

Permalink
chore: add translation keys
Browse files Browse the repository at this point in the history
  • Loading branch information
sprocketc authored and andelf committed Sep 5, 2022
1 parent 2f53ab0 commit 668849a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/main/frontend/components/block.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@
(let [image-src (string/replace src #"^assets://" "")]
[:.asset-action-bar
[:button.asset-action-btn.text-left
{:title (if local? "Show image in folder" "Open image")
{:title (t (if local? :asset/show-in-folder :asset/open-in-browser))
:on-mouse-down util/stop
:on-click (fn [e]
(util/stop e)
Expand All @@ -323,7 +323,7 @@
image-src]
[:.flex
[:button.asset-action-btn
{:title "Delete image"
{:title (t :asset/delete)
:on-mouse-down util/stop
:on-click
(fn [e]
Expand All @@ -347,15 +347,15 @@
(ui/icon "trash")]

[:button.asset-action-btn
{:title "Copy image"
{:title (t :asset/copy)
:on-mouse-down util/stop
:on-click (fn [e]
(util/stop e)
(copy-image-to-clipboard image-src))}
(ui/icon "copy")]

[:button.asset-action-btn
{:title "Maximize image"
{:title (t :asset/maximize)
:on-mouse-down util/stop
:on-click open-lightbox}

Expand Down
5 changes: 5 additions & 0 deletions src/main/frontend/dicts.cljc
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,11 @@
:draw/more-options "More options"
:draw/back-to-logseq "Back to logseq"
:text/image "Image"
:asset/show-in-folder "Show image in folder"
:asset/open-in-browser "Open image in browser"
:asset/delete "Delete image"
:asset/copy "Copy image"
:asset/maximize "Maximize image"
:asset/confirm-delete "Are you sure you want to delete this {1}?"
:asset/physical-delete "Remove the file too (notice it can't be restored)"
:content/copy "Copy"
Expand Down

0 comments on commit 668849a

Please sign in to comment.