Skip to content

Commit

Permalink
edit-meta: allow enter on date
Browse files Browse the repository at this point in the history
Signed-off-by: Varun Patil <radialapps@gmail.com>
  • Loading branch information
pulsejet committed May 17, 2024
1 parent bb1e861 commit 2747fd5
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
14 changes: 14 additions & 0 deletions src/components/modal/EditDate.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
:placeholder="t('memories', 'Year')"
:disabled="disabled"
@input="newestChange()"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -30,6 +31,7 @@
:placeholder="t('memories', 'Month')"
:disabled="disabled"
@input="newestChange()"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -42,6 +44,7 @@
:placeholder="t('memories', 'Day')"
:disabled="disabled"
@input="newestChange()"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -54,6 +57,7 @@
:placeholder="t('memories', 'Hour')"
:disabled="disabled"
@input="newestChange(true)"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -65,6 +69,7 @@
:placeholder="t('memories', 'Minute')"
:disabled="disabled"
@input="newestChange(true)"
@keypress.enter="$emit('save')"
/>
</div>

Expand All @@ -87,6 +92,7 @@
:placeholder="t('memories', 'Year')"
:disabled="disabled"
@input="oldestChange()"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -99,6 +105,7 @@
:placeholder="t('memories', 'Month')"
:disabled="disabled"
@input="oldestChange()"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -111,6 +118,7 @@
:placeholder="t('memories', 'Day')"
:disabled="disabled"
@input="oldestChange()"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -123,6 +131,7 @@
:placeholder="t('memories', 'Hour')"
:disabled="disabled"
@input="oldestChange()"
@keypress.enter="$emit('save')"
/>
<NcTextField
class="field"
Expand All @@ -134,6 +143,7 @@
:placeholder="t('memories', 'Minute')"
:disabled="disabled"
@input="oldestChange()"
@keypress.enter="$emit('save')"
/>
</div>
</div>
Expand Down Expand Up @@ -166,6 +176,10 @@ export default defineComponent({
},
},
emits: {
save: () => true,
},
data: () => ({
sortedPhotos: [] as IPhoto[],
Expand Down
2 changes: 1 addition & 1 deletion src/components/modal/EditMetadataModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<div class="title-text">
{{ t('memories', 'Date / Time') }}
</div>
<EditDate ref="editDate" :photos="photos" :disabled="processing" />
<EditDate ref="editDate" :photos="photos" :disabled="processing" @save="save" />
</div>

<div v-if="config.systemtags_enabled && sections.includes(2)">
Expand Down

0 comments on commit 2747fd5

Please sign in to comment.