Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/tetsuoanimation/kitsu
Browse files Browse the repository at this point in the history
  • Loading branch information
tetsuoanimation committed Dec 31, 2024
2 parents 210d234 + 22ec32a commit e0ae9b6
Show file tree
Hide file tree
Showing 19 changed files with 604 additions and 315 deletions.
218 changes: 109 additions & 109 deletions package-lock.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "kitsu",
"version": "0.20.10",
"version": "0.20.11",
"description": "Production Management Software (user interface)",
"author": "Frank Rousseau <[email protected]>",
"repository": "https://github.com/cgwire/kitsu",
Expand Down Expand Up @@ -64,7 +64,7 @@
"vuedraggable": "4.1.0",
"vuex": "4.1.0",
"vuex-router-sync": "6.0.0-rc.1",
"wavesurfer.js": "7.8.11"
"wavesurfer.js": "7.8.14"
},
"devDependencies": {
"@vitejs/plugin-vue": "5.2.1",
Expand All @@ -78,7 +78,7 @@
"esm": "3.2.25",
"husky": "8.0.3",
"jsdom": "24.1.3",
"lint-staged": "15.2.11",
"lint-staged": "15.3.0",
"localStorage": "1.0.4",
"prettier": "3.4.2",
"sass": "1.78.0",
Expand Down
2 changes: 1 addition & 1 deletion scripts/release.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
set -e
git pull --rebase origin main
npm version patch
git push origin main --tag
git push origin main --tags
20 changes: 6 additions & 14 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -985,14 +985,17 @@ label.label {
text-transform: uppercase;
}
texarea,
input.input {
padding: 1em;
height: 3em;
}
.select select {
border-radius: 10px;
.datatable & {
border-radius: 3px;
}
}
.select select:hover,
Expand Down Expand Up @@ -2134,14 +2137,6 @@ th.validation-cell {
}
}
.theme .datepicker input {
width: 150px;
&.short {
width: 112px;
}
}
.theme .vue-slider-dot-tooltip-inner {
background: $purple-strong;
border-color: $purple-strong;
Expand Down Expand Up @@ -2277,16 +2272,13 @@ th.validation-cell {
#app .dp__input {
border-radius: 10px;
padding-left: 0;
height: 40px;
padding-inline-start: 0.8em;
width: 116px;
width: 118px;
}
#app .datatable .dp__input {
border-radius: 2px;
border-radius: 3px;
height: 43px;
width: 116px;
}
@media screen and (max-width: 768px) {
Expand Down
12 changes: 7 additions & 5 deletions src/components/lists/AssetList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -565,10 +565,12 @@ import { mapGetters, mapActions } from 'vuex'
import { descriptorMixin } from '@/components/mixins/descriptors'
import { entityListMixin } from '@/components/mixins/entity_list'
import { formatListMixin } from '@/components/mixins/format'
import { range } from '@/lib/time'
import { sortTaskTypes } from '@/lib/sorting'
import { selectionListMixin } from '@/components/mixins/selection'
import preferences from '@/lib/preferences'
import { sortTaskTypes } from '@/lib/sorting'
import { range } from '@/lib/time'
import ButtonSimple from '@/components/widgets/ButtonSimple.vue'
import ComboboxTaskType from '@/components/widgets/ComboboxTaskType.vue'
import DescriptionCell from '@/components/cells/DescriptionCell.vue'
Expand Down Expand Up @@ -936,9 +938,9 @@ export default {
...this.stickedColumns,
[columnId]: sticked
}
localStorage.setItem(
preferences.setObjectPreference(
this.localStorageStickKey,
JSON.stringify(this.stickedColumns)
this.stickedColumns
)
},
Expand Down Expand Up @@ -1017,7 +1019,7 @@ export default {
mounted() {
this.stickedColumns =
JSON.parse(localStorage.getItem(this.localStorageStickKey)) || {}
preferences.getObjectPreference(this.localStorageStickKey) || {}
}
}
</script>
Expand Down
8 changes: 5 additions & 3 deletions src/components/lists/EditList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -474,7 +474,9 @@
<script>
import { mapGetters, mapActions } from 'vuex'
import preferences from '@/lib/preferences'
import { range } from '@/lib/time'
import { descriptorMixin } from '@/components/mixins/descriptors'
import { domMixin } from '@/components/mixins/dom'
import { entityListMixin } from '@/components/mixins/entity_list'
Expand Down Expand Up @@ -761,9 +763,9 @@ export default {
...this.stickedColumns,
[columnId]: sticked
}
localStorage.setItem(
preferences.setObjectPreference(
this.localStorageStickKey,
JSON.stringify(this.stickedColumns)
this.stickedColumns
)
},
Expand Down Expand Up @@ -831,7 +833,7 @@ export default {
mounted() {
this.stickedColumns =
JSON.parse(localStorage.getItem(this.localStorageStickKey)) || {}
preferences.getObjectPreference(this.localStorageStickKey) || {}
}
}
</script>
Expand Down
35 changes: 27 additions & 8 deletions src/components/lists/ShotList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,8 @@
<tbody
class="datatable-body"
:key="getGroupKey(group, k, 'sequence_id')"
@mousedown="startBrowsing"
@touchstart="startBrowsing"
v-for="(group, k) in displayedShots"
>
<tr class="datatable-type-header">
Expand Down Expand Up @@ -703,7 +705,9 @@
<script>
import { mapGetters, mapActions } from 'vuex'
import preferences from '@/lib/preferences'
import { range } from '@/lib/time'
import { descriptorMixin } from '@/components/mixins/descriptors'
import { domMixin } from '@/components/mixins/dom'
import { entityListMixin } from '@/components/mixins/entity_list'
Expand Down Expand Up @@ -805,10 +809,30 @@ export default {
timeSpent: true
},
offsets: {},
stickedColumns: {}
stickedColumns: {},
domEvents: [
['mousemove', this.onMouseMove],
['touchmove', this.onMouseMove],
['mouseup', this.stopBrowsing],
['mouseleave', this.stopBrowsing],
['touchend', this.stopBrowsing],
['touchcancel', this.stopBrowsing],
['keyup', this.stopBrowsing]
]
}
},
mounted() {
this.stickedColumns =
preferences.getObjectPreference(this.localStorageStickKey) || {}
this.addEvents(this.domEvents)
},
beforeUnmount() {
this.removeEvents(this.domEvents)
document.body.style.cursor = 'default'
},
computed: {
...mapGetters([
'currentProduction',
Expand Down Expand Up @@ -1078,9 +1102,9 @@ export default {
...this.stickedColumns,
[columnId]: sticked
}
localStorage.setItem(
preferences.setObjectPreference(
this.localStorageStickKey,
JSON.stringify(this.stickedColumns)
this.stickedColumns
)
},
Expand Down Expand Up @@ -1144,11 +1168,6 @@ export default {
isBigThumbnails() {
this.updateOffsets()
}
},
mounted() {
this.stickedColumns =
JSON.parse(localStorage.getItem(this.localStorageStickKey)) || {}
}
}
</script>
Expand Down
60 changes: 57 additions & 3 deletions src/components/mixins/entity_list.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import colors from '@/lib/colors'
import preferences from '@/lib/preferences'
import stringHelpers from '@/lib/string'

import assetStore from '@/store/modules/assets'
Expand Down Expand Up @@ -33,7 +34,7 @@ export const entityListMixin = {
window.addEventListener('keydown', this.onKeyDown, false)
window.addEventListener('keyup', this.onKeyUp, false)
this.stickedColumns =
JSON.parse(localStorage.getItem(this.localStorageStickKey)) || {}
preferences.getObjectPreference(this.localStorageStickKey) || {}
},

beforeUnmount() {
Expand Down Expand Up @@ -474,9 +475,9 @@ export const entityListMixin = {
...this.stickedColumns,
[columnId]: sticked
}
localStorage.setItem(
preferences.setObjectPreference(
this.localStorageStickKey,
JSON.stringify(this.stickedColumns)
this.stickedColumns
)
},

Expand Down Expand Up @@ -545,6 +546,59 @@ export const entityListMixin = {
})
}
}
},

startBrowsing(event) {
document.body.style.cursor = 'grabbing'
this.isBrowsingX = true
this.isBrowsingY = true
this.initialClientX = this.getClientX(event)
this.initialClientY = this.getClientY(event)
},

startBrowsingX(event) {
document.body.style.cursor = 'grabbing'
this.isBrowsingX = true
this.initialClientX = this.getClientX(event)
},

startBrowsingY(event) {
document.body.style.cursor = 'grabbing'
this.isBrowsingY = true
this.initialClientY = this.getClientY(event)
},

stopBrowsing(event) {
document.body.style.cursor = 'default'
this.isBrowsingX = false
this.isBrowsingY = false
this.initialClientX = null
this.initialClientY = null
},

onMouseMove(event) {
if (this.isBrowsingX) this.scrollTableLeft(event)
if (this.isBrowsingY) this.scrollTableTop(event)
},

scrollTableLeft(event) {
const tableWrapper = this.$refs.body
const previousLeft = tableWrapper.scrollLeft
const movementX =
event.movementX || this.getClientX(event) - this.initialClientX
const newLeft = previousLeft - movementX
this.initialClientX = this.getClientX(event)
tableWrapper.scrollLeft = newLeft
},

scrollTableTop(event) {
const tableWrapper = this.$refs.body
const previousTop = tableWrapper.scrollTop
const movementY =
event.movementY || this.getClientY(event) - this.initialClientY
const newTop = previousTop - movementY
this.initialClientY = this.getClientY(event)
tableWrapper.scrollTop = newTop
}
},

Expand Down
59 changes: 27 additions & 32 deletions src/components/pages/ProductionNewsFeed.vue
Original file line number Diff line number Diff line change
Expand Up @@ -154,23 +154,20 @@
</div>

<div class="flexrow-item comment-content">
<div>
<div class="news-info flexrow">
<span class="explaination flexrow-item flexrow">
<entity-thumbnail
class="ml1 entity-thumbnail mr1 flexrow-item"
:entity="{
id: news.task_entity_id,
preview_file_id: news.entity_preview_file_id
}"
:with-link="false"
/>

<span class="strong ml05">
{{ news.full_entity_name }}
</span>
<div class="news-info flexrow">
<span class="flexrow-item flexrow">
<entity-thumbnail
class="ml1 entity-thumbnail mr1 flexrow-item"
:entity="{
id: news.task_entity_id,
preview_file_id: news.entity_preview_file_id
}"
:with-link="false"
/>
<span class="strong ml05">
{{ news.full_entity_name }}
</span>
</div>
</span>
</div>
</div>
</div>
Expand Down Expand Up @@ -217,23 +214,21 @@
</div>

<div class="flexrow-item comment-content">
<div>
<div class="news-info flexrow">
<span class="explaination flexrow-item flexrow">
<entity-thumbnail
class="ml1"
:entity="{
id: news.task_entity_id,
preview_file_id: news.entity_preview_file_id
}"
:with-link="false"
v-if="news.entity_preview_file_id"
/>
<span class="strong ml05 flexrow-item">
{{ news.full_entity_name }}
</span>
<div class="news-info flexrow">
<span class="flexrow-item flexrow">
<entity-thumbnail
class="ml1"
:entity="{
id: news.task_entity_id,
preview_file_id: news.entity_preview_file_id
}"
:with-link="false"
v-if="news.entity_preview_file_id"
/>
<span class="strong ml05 flexrow-item">
{{ news.full_entity_name }}
</span>
</div>
</span>
</div>
</div>
</div>
Expand Down
Loading

0 comments on commit e0ae9b6

Please sign in to comment.