Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"moment-timezone": "0.6.1",
"panzoom": "9.4.4",
"papaparse": "5.5.3",
"qrcode.vue": "3.8.0",
"qrcode.vue": "3.8.1",
"sanitize-html": "2.17.2",
"socket.io-client": "4.8.3",
"superagent": "10.3.0",
Expand Down Expand Up @@ -85,7 +85,7 @@
"lint-staged": "16.4.0",
"localStorage": "1.0.4",
"prettier": "3.8.1",
"sass": "1.98.0",
"sass": "1.99.0",
"vite": "8.0.3",
"vitest": "4.1.2",
"vitest-localstorage-mock": "0.1.2",
Expand Down
5 changes: 4 additions & 1 deletion src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -1109,9 +1109,12 @@ input.input {
.select select:active,
.select select:focus,
input.input:focus {
border-color: #00b242;
border-color: $green;
outline: none;
}
.select select:required:invalid {
border-color: $red;
}

.button,
.button.is-small {
Expand Down
3 changes: 1 addition & 2 deletions src/components/modals/AddMetadataModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -287,8 +287,7 @@ export default {
(['string', 'number', 'boolean'].includes(this.form.data_type) ||
(['list', 'taglist'].includes(this.form.data_type) &&
this.form.values.length) ||
(this.form.data_type === 'checklist' &&
this.checklist?.[0]?.text.length)) &&
(this.form.data_type === 'checklist' && this.checklist?.[0]?.text)) &&
(!this.isCurrentUserSupervisor ||
!this.user.departments.length ||
this.form.departments.length)
Expand Down
14 changes: 9 additions & 5 deletions src/components/modals/EditAssetModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<combobox
:label="$t('assets.fields.episode')"
:options="episodeOptions"
required
v-model="form.source_id"
v-if="isTVShow"
/>
Expand Down Expand Up @@ -166,7 +167,7 @@ export default {
form: {
name: '',
description: '',
source_id: null,
source_id: 'null',
data: {
resolution: ''
},
Expand Down Expand Up @@ -276,9 +277,11 @@ export default {
}
this.form.name = ''
this.form.description = ''
this.form.source_id = this.currentEpisode
? this.currentEpisode.id
: null
this.form.source_id =
this.currentEpisode &&
!['all', 'main'].includes(this.currentEpisode.id)
? this.currentEpisode.id
: 'null'
this.form.data = {}
this.form.is_shared = 'false'
} else {
Expand All @@ -288,7 +291,8 @@ export default {
project_id: this.assetToEdit.project_id,
name: this.assetToEdit.name,
description: this.assetToEdit.description,
source_id: this.assetToEdit.source_id || this.assetToEdit.episode_id,
source_id:
this.assetToEdit.source_id || this.assetToEdit.episode_id || 'null',
data:
{
...this.assetToEdit.data,
Expand Down
2 changes: 1 addition & 1 deletion src/components/modals/EditCommentModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ export default {
id: this.commentToEdit.id,
text: this.form.text,
task_status_id: this.form.task_status_id,
checklist: this.form.checklist.filter(item => item.text.length),
checklist: this.form.checklist.filter(item => item.text),
newAttachmentFiles: this.attachmentFiles,
attachmentFilesToDelete: this.attachmentFilesToDelete,
links: this.form.link ? [this.form.link] : null
Expand Down
3 changes: 2 additions & 1 deletion src/components/modals/EditPersonModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
:label="$t('people.fields.email')"
:disabled="personToEdit.is_generated_from_ldap"
v-model.trim="form.email"
@update:model-value="$emit('reset-error', 'email')"
v-if="!isBot"
/>
<text-field
Expand Down Expand Up @@ -280,7 +281,7 @@ export default {
}
},

emits: ['cancel'],
emits: ['cancel', 'reset-error'],

data() {
return {
Expand Down
52 changes: 32 additions & 20 deletions src/components/modals/PreviewModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,33 @@
}"
>
<div class="modal-background" @click="$emit('cancel')"></div>
<div class="new-window">
<a class="mr1" :href="previewDlPath" v-if="previewFileId">
<arrow-down-icon />
<div class="actions">
<a
:href="previewDlPath"
:title="$t('playlists.actions.download_file')"
v-if="previewFileId"
>
<download-icon />
</a>
<a target="_blank" :href="previewPath">
<a
:href="previewPath"
target="_blank"
:title="$t('playlists.actions.see_original_file')"
>
<arrow-up-right-icon />
</a>
<span class="pointer" :title="$t('main.close')" @click="$emit('cancel')">
<x-icon />
</span>
</div>

<div class="modal-content" @click="$emit('cancel')">
<img :src="previewPath" />
</div>
</div>
</template>

<script>
import { ArrowDownIcon, ArrowUpRightIcon } from 'lucide-vue-next'
import { ArrowUpRightIcon, DownloadIcon, XIcon } from 'lucide-vue-next'

import { getDownloadAttachmentPath } from '@/lib/path'

Expand All @@ -34,8 +44,9 @@ export default {
mixins: [modalMixin],

components: {
ArrowDownIcon,
ArrowUpRightIcon
ArrowUpRightIcon,
DownloadIcon,
XIcon
},

props: {
Expand All @@ -58,41 +69,42 @@ export default {
computed: {
previewPath() {
if (this.previewFileId) {
const id = this.previewFileId
return this.active && this.previewFileId
? '/api/pictures/originals/preview-files/' + id + '.png'
return this.active
? `/api/pictures/originals/preview-files/${this.previewFileId}.png`
: ''
} else if (this.attachment) {
}
if (this.attachment) {
return getDownloadAttachmentPath(this.attachment)
}
return ''
},

previewDlPath() {
const previewId = this.previewFileId
return `/api/pictures/originals/preview-files/${previewId}/download`
return `/api/pictures/originals/preview-files/${this.previewFileId}/download`
}
}
}
</script>

<style lang="scss" scoped>
.error {
margin-top: 1em;
}

.new-window {
.actions {
display: inline-flex;
gap: 1em;
color: $grey;
position: absolute;
right: 1em;
top: 1em;
z-index: 2;

& > *:hover {
color: $light-grey;
}
}

.modal-content {
width: 100%;
text-align: center;
max-height: 100vh;
max-height: 100vmax;

img {
max-height: 100vh;
Expand Down
7 changes: 7 additions & 0 deletions src/components/pages/People.vue
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@
@confirm="confirmEditPeople"
@confirm-invite="confirmCreateAndInvite"
@invite="confirmInvite"
@reset-error="resetError"
v-if="modals.edit"
/>

Expand Down Expand Up @@ -530,6 +531,12 @@ export default {
})
},

resetError(error) {
if (error === 'email') {
this.errors.invalidEmailDomain = false
}
},

onSearchChange() {
if (this.searchField) {
const searchQuery = this.searchField?.getValue()
Expand Down
2 changes: 1 addition & 1 deletion src/components/previews/PreviewPlayer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -1164,7 +1164,7 @@ export default {
},

focus() {
this.$refs.container.focus()
this.$refs.container?.focus()
},

timeCodeClicked({ versionRevision, frame }) {
Expand Down
2 changes: 1 addition & 1 deletion src/components/widgets/AddComment.vue
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,7 @@ export default {
attachments = []
checklist = []
} else {
checklist = checklist.filter(item => item.text.length)
checklist = checklist.filter(item => item.text)
}

revision = Number(revision)
Expand Down
4 changes: 2 additions & 2 deletions src/components/widgets/Checklist.vue
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
@keyup.backspace="removeChecklistEntry(index)"
@keyup.up="focusPrevious(index)"
@keyup.down="focusNext(index)"
:disabled="entry.text.length !== 0 && disabled"
:disabled="entry.text?.length !== 0 && disabled"
v-autosize
v-model.trim="entry.text"
></textarea>
Expand Down Expand Up @@ -127,7 +127,7 @@ export default {

removeChecklistEntry(index) {
const entry = this.checklist[index]
if (entry.text.length === 0) {
if (!entry.text) {
this.$emit('remove-task', entry)
this.focusPrevious(index)
}
Expand Down
5 changes: 5 additions & 0 deletions src/components/widgets/Combobox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
}"
ref="select"
:disabled="disabled"
:required="required && !hasSelectedOption"
@keyup.enter="emitEnter()"
@change="updateValue"
>
Expand Down Expand Up @@ -85,6 +86,10 @@ export default {
isInline: {
default: false,
type: Boolean
},
required: {
default: false,
type: Boolean
}
},

Expand Down
2 changes: 1 addition & 1 deletion src/components/widgets/Comment.vue
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,7 @@ export default {
this.lastCall = now
const comment = {
id: this.comment.id,
checklist: this.checklist.filter(item => item.text?.length)
checklist: this.checklist.filter(item => item.text)
}
this.$emit('checklist-updated', comment)
}
Expand Down
3 changes: 1 addition & 2 deletions src/store/modules/tasks.js
Original file line number Diff line number Diff line change
Expand Up @@ -385,9 +385,8 @@ const actions = {
const selectedTaskIds = Array.from(state.selectedTasks.keys())
for (const taskId of selectedTaskIds) {
const task = state.taskMap.get(taskId)
const taskType = rootGetters.taskTypeMap.get(task.task_type_id)

if (task && task.priority !== priority) {
const taskType = rootGetters.taskTypeMap.get(task.task_type_id)
const updatedTask = await tasksApi.updateTask(taskId, { priority })
commit(EDIT_TASK_END, { task: updatedTask, taskType })
}
Expand Down