mirror of
https://github.com/penpot/penpot.git
synced 2025-06-07 21:32:56 +02:00
♻️ Update download button icon
This commit is contained in:
parent
c8146cf0fe
commit
f0735417f4
6 changed files with 29 additions and 24 deletions
3
frontend/resources/images/icons/import-export.svg
Normal file
3
frontend/resources/images/icons/import-export.svg
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" stroke-linecap="round" stroke-linejoin="round">
|
||||||
|
<path d="m8.5 8.658-2-1.657m0 0-2 1.657m2-1.657V11.5m6 1.842-2 1.657m0 0-2-1.657m2 1.657V10.5m3.15.104a3.18 3.18 0 0 0-1.832-5.78h-.802A5.088 5.088 0 1 0 2.278 9.46"/>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 286 B |
|
@ -164,6 +164,7 @@
|
||||||
(def ^:icon-id icon "icon")
|
(def ^:icon-id icon "icon")
|
||||||
(def ^:icon-id img "img")
|
(def ^:icon-id img "img")
|
||||||
(def ^:icon-id info "info")
|
(def ^:icon-id info "info")
|
||||||
|
(def ^:icon-id import-export "import-export")
|
||||||
(def ^:icon-id interaction "interaction")
|
(def ^:icon-id interaction "interaction")
|
||||||
(def ^:icon-id join-nodes "join-nodes")
|
(def ^:icon-id join-nodes "join-nodes")
|
||||||
(def ^:icon-id justify-content-column-around "justify-content-column-around")
|
(def ^:icon-id justify-content-column-around "justify-content-column-around")
|
||||||
|
|
|
@ -333,6 +333,7 @@
|
||||||
(js/JSON.stringify nil 2)
|
(js/JSON.stringify nil 2)
|
||||||
(wapi/create-blob "application/json"))]
|
(wapi/create-blob "application/json"))]
|
||||||
(dom/trigger-download "tokens.json" tokens-blob)))]
|
(dom/trigger-download "tokens.json" tokens-blob)))]
|
||||||
|
|
||||||
[:div {:class (stl/css :import-export-button-wrapper)}
|
[:div {:class (stl/css :import-export-button-wrapper)}
|
||||||
[:input {:type "file"
|
[:input {:type "file"
|
||||||
:ref input-ref
|
:ref input-ref
|
||||||
|
@ -340,20 +341,20 @@
|
||||||
:id "file-input"
|
:id "file-input"
|
||||||
:accept ".json"
|
:accept ".json"
|
||||||
:on-change on-import}]
|
:on-change on-import}]
|
||||||
[:button {:class (stl/css :import-export-button)
|
[:> button* {:on-click open-menu
|
||||||
:on-click open-menu}
|
:icon "import-export"
|
||||||
download-icon
|
:variant "secondary"}
|
||||||
"Tokens"]
|
(tr "workspace.token.tools")]
|
||||||
[:& dropdown-menu {:show show-menu?
|
[:& dropdown-menu {:show show-menu?
|
||||||
:on-close close-menu
|
:on-close close-menu
|
||||||
:list-class (stl/css :import-export-menu)}
|
:list-class (stl/css :import-export-menu)}
|
||||||
[:> dropdown-menu-item* {:class (stl/css :import-export-menu-item)
|
[:> dropdown-menu-item* {:class (stl/css :import-export-menu-item)
|
||||||
:on-click #(.click (mf/ref-val input-ref))}
|
:on-click #(.click (mf/ref-val input-ref))}
|
||||||
"Import"]
|
(tr "labels.import")]
|
||||||
|
|
||||||
[:> dropdown-menu-item* {:class (stl/css :import-export-menu-item)
|
[:> dropdown-menu-item* {:class (stl/css :import-export-menu-item)
|
||||||
:on-click on-export}
|
:on-click on-export}
|
||||||
"Export"]]]))
|
(tr "labels.export")]]]))
|
||||||
|
|
||||||
(mf/defc tokens-sidebar-tab
|
(mf/defc tokens-sidebar-tab
|
||||||
{::mf/wrap [mf/memo]
|
{::mf/wrap [mf/memo]
|
||||||
|
|
|
@ -119,28 +119,11 @@
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
align-items: end;
|
align-items: end;
|
||||||
justify-content: end;
|
justify-content: end;
|
||||||
padding: $s-16;
|
padding: $s-8;
|
||||||
margin-top: $s-8;
|
|
||||||
background-color: var(--color-background-primary);
|
background-color: var(--color-background-primary);
|
||||||
box-shadow: var(--el-shadow-dark);
|
box-shadow: var(--el-shadow-dark);
|
||||||
}
|
}
|
||||||
|
|
||||||
.import-export-button {
|
|
||||||
@extend .button-secondary;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
padding: $s-6 $s-8;
|
|
||||||
text-transform: uppercase;
|
|
||||||
gap: $s-8;
|
|
||||||
|
|
||||||
.download-icon {
|
|
||||||
@extend .button-icon;
|
|
||||||
stroke: var(--icon-foreground);
|
|
||||||
width: 20px;
|
|
||||||
height: 20px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.import-export-menu {
|
.import-export-menu {
|
||||||
@extend .menu-dropdown;
|
@extend .menu-dropdown;
|
||||||
top: -#{$s-6};
|
top: -#{$s-6};
|
||||||
|
|
|
@ -1721,6 +1721,10 @@ msgstr "Expired"
|
||||||
msgid "labels.export"
|
msgid "labels.export"
|
||||||
msgstr "Export"
|
msgstr "Export"
|
||||||
|
|
||||||
|
#: src/app/main/ui/exports/assets.cljs:177
|
||||||
|
msgid "labels.import"
|
||||||
|
msgstr "Import"
|
||||||
|
|
||||||
#: src/app/main/ui/settings/feedback.cljs:48
|
#: src/app/main/ui/settings/feedback.cljs:48
|
||||||
msgid "labels.feedback-disabled"
|
msgid "labels.feedback-disabled"
|
||||||
msgstr "Feedback disabled"
|
msgstr "Feedback disabled"
|
||||||
|
@ -6613,6 +6617,10 @@ msgstr "Create one."
|
||||||
msgid "workspace.token.add set"
|
msgid "workspace.token.add set"
|
||||||
msgstr "Add set"
|
msgstr "Add set"
|
||||||
|
|
||||||
|
#: src/app/main/ui/workspace/tokens/sidebar.cljs
|
||||||
|
msgid "workspace.token.tools"
|
||||||
|
msgstr "Tools"
|
||||||
|
|
||||||
#: src/app/main/ui/workspace/tokens/modals/themes.cljs
|
#: src/app/main/ui/workspace/tokens/modals/themes.cljs
|
||||||
msgid "workspace.token.save-theme"
|
msgid "workspace.token.save-theme"
|
||||||
msgstr "Save theme"
|
msgstr "Save theme"
|
||||||
|
|
|
@ -1727,6 +1727,11 @@ msgstr "Expirada"
|
||||||
msgid "labels.export"
|
msgid "labels.export"
|
||||||
msgstr "Exportar"
|
msgstr "Exportar"
|
||||||
|
|
||||||
|
|
||||||
|
#: src/app/main/ui/exports/assets.cljs:177
|
||||||
|
msgid "labels.import"
|
||||||
|
msgstr "Importar"
|
||||||
|
|
||||||
#: src/app/main/ui/settings/feedback.cljs:48
|
#: src/app/main/ui/settings/feedback.cljs:48
|
||||||
msgid "labels.feedback-disabled"
|
msgid "labels.feedback-disabled"
|
||||||
msgstr "El modulo de recepción de opiniones esta deshabilitado"
|
msgstr "El modulo de recepción de opiniones esta deshabilitado"
|
||||||
|
@ -6612,6 +6617,10 @@ msgstr "Crear uno."
|
||||||
msgid "workspace.token.add set"
|
msgid "workspace.token.add set"
|
||||||
msgstr "Añadir set"
|
msgstr "Añadir set"
|
||||||
|
|
||||||
|
#: src/app/main/ui/workspace/tokens/sidebar.cljs
|
||||||
|
msgid "workspace.token.tools"
|
||||||
|
msgstr "Herramientas"
|
||||||
|
|
||||||
#: src/app/main/ui/workspace/tokens/modals/themes.cljs
|
#: src/app/main/ui/workspace/tokens/modals/themes.cljs
|
||||||
msgid "workspace.token.save-theme"
|
msgid "workspace.token.save-theme"
|
||||||
msgstr "Guardar tema"
|
msgstr "Guardar tema"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue