Skip to content

Commit

Permalink
Merge pull request #4092 from owncloud/improve-oc10-link
Browse files Browse the repository at this point in the history
Improve oc10 link
  • Loading branch information
kulmann authored Sep 21, 2020
2 parents 07c1566 + d786819 commit 4c4ca70
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 7 deletions.
5 changes: 5 additions & 0 deletions changelog/unreleased/external-links
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Change: Improve external links in app switcher

We have added an option to set the link target in external application links (defaults to `_blank`). The app switcher now shows all native extensions first and items based on application links last.

https://github.com/owncloud/phoenix/pull/4092
6 changes: 3 additions & 3 deletions src/Phoenix.vue
Original file line number Diff line number Diff line change
Expand Up @@ -106,14 +106,14 @@ export default {
$_applicationsList() {
const list = []
// Get extensions manually added into config
list.push(this.configuration.applications)
// Get extensions which have at least one nav item
this.getExtensionsWithNavItems.forEach(extensionId => {
list.push(this.apps[extensionId])
})
// Get extensions manually added into config
list.push(this.configuration.applications)
return list.flat()
},
Expand Down
5 changes: 4 additions & 1 deletion src/components/ApplicationsMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
>
<div class="uk-grid-small uk-text-center" uk-grid>
<div v-for="(n, nid) in $_applicationsList" :key="nid" class="uk-width-1-3">
<a v-if="n.url" key="external-link" target="_blank" :href="n.url">
<a v-if="n.url" key="external-link" :target="n.target" :href="n.url">
<oc-icon v-if="n.iconMaterial" :name="n.iconMaterial" size="large" />
<oc-icon v-if="n.iconUrl" :url="n.iconUrl" size="large" />
<div>{{ n.title }}</div>
Expand Down Expand Up @@ -85,6 +85,9 @@ export default {
if (item.url) {
app.url = item.url
app.target = ['_blank', '_self', '_parent', '_top'].includes(item.target)
? item.target
: '_blank'
} else if (item.path) {
app.path = item.path
} else {
Expand Down
6 changes: 3 additions & 3 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6907,9 +6907,9 @@ os-tmpdir@~1.0.1, os-tmpdir@~1.0.2:
integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=

owncloud-design-system@^1.9.0:
version "1.11.0"
resolved "https://registry.yarnpkg.com/owncloud-design-system/-/owncloud-design-system-1.11.0.tgz#cdeac879c7292e4520087913cb3b83425254d438"
integrity sha512-oQcgNDRB1fvq6wSQiApFu0nRI2j1SmLurOngG8dgXlABm9ArOA3K4crcjT/YdUjlFL0JnC64v5MUYWEQhQxTrA==
version "1.11.1"
resolved "https://registry.yarnpkg.com/owncloud-design-system/-/owncloud-design-system-1.11.1.tgz#8afa0117d2d7d86bec6fb0e3198c17c10328fa79"
integrity sha512-ULrf/LOkHhRaBX3VoprHRg69n51Gu8AaOiu1jzIAJzRxE40XM+kv8sXNBvjoxeiZZBX6WHVQCmXCyysKI5Yatg==
dependencies:
luxon "^1.22.0"
mini-css-extract-plugin "^0.9.0"
Expand Down

0 comments on commit 4c4ca70

Please sign in to comment.