This commit is contained in:
Čarodej
2022-03-20 19:00:46 +01:00
parent 73ef6e6c1f
commit 42245317f4
10 changed files with 44 additions and 24 deletions

View File

@@ -33,3 +33,9 @@
.page-link {
@apply block flex h-8 w-8 cursor-pointer items-center justify-center rounded-lg text-sm font-bold transition duration-200 hover:bg-light-background;
}
@layer utilities {
.overflow-initial {
overflow: initial;
}
}

View File

@@ -1,8 +1,8 @@
<template>
<div
class="sticky top-14 z-[19] overflow-x-auto whitespace-nowrap bg-white px-4 pb-3 dark:bg-dark-background lg:hidden"
class="sticky top-14 z-[19] whitespace-nowrap bg-white dark:bg-dark-background lg:hidden"
>
<div class="flex items-center">
<div class="flex items-center overflow-x-auto pb-3 pl-4">
<!--Show Buttons-->
<slot v-if="!isMultiSelectMode" />

View File

@@ -9,7 +9,7 @@
spellcheck="false"
>
<!--MultiSelecting for the mobile version-->
<CheckBox v-if="isMultiSelectMode" v-model="isClicked" :is-clicked="isClicked" class="mr-5" />
<CheckBox v-if="isMultiSelectMode" v-model="isChecked" :is-clicked="isClicked" class="mr-5" />
<!--Item thumbnail-->
<div class="relative w-16 shrink-0">
@@ -125,11 +125,21 @@ export default {
Emoji,
},
props: ['mobileHandler', 'highlight', 'entry'],
watch: {
isChecked: function (val) {
if (val) {
this.$store.commit('ADD_ITEM_TO_CLIPBOARD', this.entry)
} else {
this.$store.commit('REMOVE_ITEM_FROM_CLIPBOARD', this.entry.data.id)
}
}
},
data() {
return {
mobileMultiSelect: false,
itemName: undefined,
isSelected: false,
isChecked: false,
}
},
computed: {

View File

@@ -4,7 +4,7 @@
<PopupHeader :title="$t('create_language')" icon="edit" />
<!--Content-->
<PopupContent>
<PopupContent class="!overflow-initial">
<!--Form to set sharing-->
<ValidationObserver @submit.prevent="createLanguage" ref="createForm" v-slot="{ invalid }" tag="form">
<ValidationProvider

View File

@@ -10,14 +10,14 @@
<!--Folder tree-->
<div v-if="!isLoadingTree && navigation">
<ThumbnailItem v-if="clipboard.length < 2 || isSelectedItem" class="mb-5" :item="pickedItem" />
<ThumbnailItem v-if="clipboard.length === 1 || isSelectedItem" class="mb-5" :item="pickedItem" />
<TitlePreview
class="mb-4"
icon="check-square"
:title="$t('selected_multiple')"
:subtitle="this.clipboard.length + ' ' + $tc('items', this.clipboard.length)"
v-if="clipboard.length > 1 && !isSelectedItem"
:subtitle="clipboard.length + ' ' + $tc('items', clipboard.length)"
v-if="clipboard.length > 1 || !isSelectedItem"
/>
<TreeMenu

View File

@@ -4,7 +4,7 @@
<PopupHeader :title="$t('popup_share_create.title', { item: itemTypeTitle })" icon="share" />
<!--Content-->
<PopupContent>
<PopupContent class="!overflow-initial">
<!--Item Thumbnail-->
<ThumbnailItem class="mb-5" :item="pickedItem" />

View File

@@ -1,6 +1,7 @@
import i18n from '../i18n'
import store from '../store/index'
import { events } from '../bus'
import {isArray} from "lodash";
const itemHelpers = {
install(Vue) {
@@ -39,7 +40,10 @@ const itemHelpers = {
}
Vue.prototype.$moveFileOrFolder = function (entry) {
events.$emit('popup:open', { name: 'move', item: [entry] })
let item = isArray(entry) ? [...entry] : [entry]
events.$emit('popup:open', { name: 'move', item: item })
}
Vue.prototype.$createFolderByPopup = function () {