Skip to content

Commit

Permalink
added fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Yehor Podporinov authored and Yehor Podporinov committed Sep 25, 2023
1 parent 8c5b48e commit 38cb5fc
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 7 deletions.
3 changes: 1 addition & 2 deletions components/AppFooter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@
.app-footer {
display: flex;
gap: toRem(24);
padding: toRem(24) var(--app-padding-right) toRem(24) var(--app-padding-left);
justify-content: center;
padding: toRem(24) toRem(80);
border-top: toRem(1) solid var(--background-primary-light);
}
Expand Down
10 changes: 5 additions & 5 deletions forms/TimestampForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
import { AppCopy } from '#components'
import { useFormValidation } from '@/composables'
import { InputField } from '@/fields'
import { integer, maxValue, minValue, required } from '@/helpers'
import { capitalize, integer, maxValue, minValue, required } from '@/helpers'
import { Time } from '@distributedlab/tools'
import { computed, reactive } from 'vue'
import { i18n } from '~/plugins/localization'
Expand Down Expand Up @@ -67,19 +67,19 @@ const time = computed<Time | null>(() =>
const outputItems = computed(() => [
{
label: t('timestamp-form.format-label'),
value: t('timestamp-form.format-value'),
value: capitalize(t('timestamp-form.format-value')),
},
{
label: t('timestamp-form.gmt-label'),
value: time.value ? time.value.toDate().toUTCString() : '',
value: time.value ? capitalize(time.value.toDate().toUTCString()) : '',
},
{
label: t('timestamp-form.time-zone-label'),
value: time.value ? time.value.toDate().toString() : '',
value: time.value ? capitalize(time.value.toDate().toString()) : '',
},
{
label: t('timestamp-form.relative-time-label'),
value: time.value ? time.value.fromNow : '',
value: time.value ? capitalize(time.value.fromNow) : '',
},
])
</script>
Expand Down
1 change: 1 addition & 0 deletions helpers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export * from './ethereum.helpers'
export * from './event-bus.helper'
export * from './clipboard.helpers'
export * from './promise.helpers'
export * from './text.helpers'
export * from './type.helpers'
export * from './validators.helpers'
export * from './hash-functions.helpers'
Expand Down
4 changes: 4 additions & 0 deletions helpers/text.helpers.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export function capitalize(str: string) {
if (!str) return ''
return str[0].toUpperCase() + str.slice(1)
}

0 comments on commit 38cb5fc

Please sign in to comment.