aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/src/components
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@protonmail.com>2023-08-09 12:31:54 +0200
committerJohn Molakvoæ <skjnldsv@protonmail.com>2023-08-17 18:56:37 +0200
commit998b3a2581fb873b03bcf4dc02eafb19390b3cd6 (patch)
tree9c90078211fa2af1e3f570540d38bec47a634bae /apps/files/src/components
parenta820e3d036741ad1194361eca11bc1cbcdda0a47 (diff)
downloadnextcloud-server-998b3a2581fb873b03bcf4dc02eafb19390b3cd6.tar.gz
nextcloud-server-998b3a2581fb873b03bcf4dc02eafb19390b3cd6.zip
feat(f2v): migrate Files
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'apps/files/src/components')
-rw-r--r--apps/files/src/components/FileEntry.vue13
-rw-r--r--apps/files/src/components/FilesListVirtual.vue14
2 files changed, 27 insertions, 0 deletions
diff --git a/apps/files/src/components/FileEntry.vue b/apps/files/src/components/FileEntry.vue
index 775c868b18e..c540cc4e824 100644
--- a/apps/files/src/components/FileEntry.vue
+++ b/apps/files/src/components/FileEntry.vue
@@ -22,6 +22,8 @@
<template>
<Fragment>
+ <span v-if="source.attributes.failed" class="files-list__row--failed" />
+
<td class="files-list__row-checkbox">
<NcCheckboxRadioSwitch v-if="active"
:aria-label="t('files', 'Select the row for {displayName}', { displayName })"
@@ -342,6 +344,13 @@ export default Vue.extend({
},
linkTo() {
+ if (this.source.attributes.failed) {
+ return {
+ title: this.t('files', 'This node is unavailable'),
+ is: 'span',
+ }
+ }
+
if (this.enabledDefaultActions.length > 0) {
const action = this.enabledDefaultActions[0]
const displayName = action.displayName([this.source], this.currentView)
@@ -404,6 +413,10 @@ export default Vue.extend({
// Sorted actions that are enabled for this node
enabledActions() {
+ if (this.source.attributes.failed) {
+ return []
+ }
+
return actions
.filter(action => !action.enabled || action.enabled([this.source], this.currentView))
.sort((a, b) => (a.order || 0) - (b.order || 0))
diff --git a/apps/files/src/components/FilesListVirtual.vue b/apps/files/src/components/FilesListVirtual.vue
index 0488e8ef190..014f0a89f00 100644
--- a/apps/files/src/components/FilesListVirtual.vue
+++ b/apps/files/src/components/FilesListVirtual.vue
@@ -197,6 +197,7 @@ export default Vue.extend({
align-items: center;
width: 100%;
border-bottom: 1px solid var(--color-border);
+ user-select: none;
}
td, th {
@@ -221,8 +222,21 @@ export default Vue.extend({
}
}
+ .files-list__row--failed {
+ position: absolute;
+ display: block;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ opacity: .1;
+ z-index: -1;
+ background: var(--color-error);
+ }
+
.files-list__row-checkbox {
justify-content: center;
+
.checkbox-radio-switch {
display: flex;
justify-content: center;