diff --git a/assets/style.less b/assets/style.less index 09f8e442..cdc10e60 100644 --- a/assets/style.less +++ b/assets/style.less @@ -18,14 +18,14 @@ html, body { .el-form-item { margin-bottom: 5px; } -.el-divider__text { - background-color: @background; - color: white; - border-radius: 5px; -} +// .el-divider__text { +// background-color: @background; +// color: white; +// border-radius: 5px; +// } .el-card { - max-width: 600px; + max-width: 650px; margin: 30px auto; } @@ -64,10 +64,14 @@ pre { word-break: normal; } -@media only screen and (min-width: 768px) { - .el-dialog { - margin-top: 10vh !important; - width: 700px; - border-radius: 3px; +@media only screen and (max-width: 768px) { + .el-card { + margin-top: 0px !important; + border-radius: 0px; + padding: 0px; + } + + .el-menu-item { + padding: 0px 17px; } } diff --git a/components/Calendar.vue b/components/Calendar.vue index e42e27f4..61cbfbce 100644 --- a/components/Calendar.vue +++ b/components/Calendar.vue @@ -44,19 +44,18 @@ export default { order: event.start_datetime, } const day = moment(event.start_datetime).date() - let color = event.past ? 'rgba(200,200,200,0.5)' : get(event, 'tags[0].color') || 'rgba(170,170,250,0.7)' + // let color = event.past ? 'rgba(200,200,200,0.5)' : get(event, 'tags[0].color') || 'rgba(170,170,250,0.7)' - console.error(color) if (event.multidate) { e.dates = { start: event.start_datetime, end: event.end_datetime } e.highlight = { - color: sample(['purple', 'red', 'green', 'blue']), + color: sample(['purple', 'yellow', 'orange', 'red', 'green', 'blue']), } } else { e.dates = event.start_datetime - e.dot = { color: sample(['purple', 'red', 'green', 'blue']) } + e.dot = { color: sample(['purple', 'red', 'orange', 'yellow', 'green', 'blue']) } } return e } @@ -85,11 +84,11 @@ export default { align-self: center; } -.vc-highlight { - /* color: red; */ +/* .vc-highlight { + color: red; height: 22px !important; opacity: 0.4; border-radius: 15px; -} +} */ diff --git a/components/Event.vue b/components/Event.vue index c65600ef..a026ae11 100644 --- a/components/Event.vue +++ b/components/Event.vue @@ -74,7 +74,7 @@ export default { img { width: 100%; - max-height: 200px; + max-height: 250px; object-fit: cover; object-position: top; } @@ -107,7 +107,7 @@ export default { } .date { - font-weight: 300; + font-weight: 400; font-size: 12px; font-size: 0.95rem; color: #ff917a; @@ -126,7 +126,7 @@ export default { background: #1B1F21; display: inline-block; padding: 2px 10px; - color: rgba(255,255,255,0.7); + color: rgba(255,255,255,0.9); margin: 1px; text-align: center; flex-grow: 1; diff --git a/components/Nav.vue b/components/Nav.vue index 4c50afc4..5b87dcad 100644 --- a/components/Nav.vue +++ b/components/Nav.vue @@ -1,24 +1,17 @@ + diff --git a/locales/email/it.json b/locales/email/it.json index c22030f9..ae40e113 100644 --- a/locales/email/it.json +++ b/locales/email/it.json @@ -1,6 +1,6 @@ { - "registration_email": "registration_email", "recover_email": "recover_email", "press here": "press here", - "register.request": "register.request" + "register.request": "register.request", + "email.registration": "porcodio" } \ No newline at end of file diff --git a/locales/it.js b/locales/it.js index b4b881e6..f9eba3f3 100644 --- a/locales/it.js +++ b/locales/it.js @@ -105,7 +105,8 @@ const it = { added: 'Evento aggiunto', added_anon: 'Evento aggiunto, verrà confermato quanto prima.', where_description: `Dov'è il gancio? Se il posto non è presente, scrivilo e premi invio. `, - confirmed: 'Evento confermato' + confirmed: 'Evento confermato', + not_found: 'Evento non trovato' }, admin: { @@ -126,14 +127,16 @@ const it = { err: { register_error: 'Errore nella registrazione' - }, - - firstrun: { - basic: `Inserisci titolo e descrizione della tua istanza di gancio.`, - database: `Gancio ha bisogno di un database postgresql!`, - smtp: `Inserisci un account SMTP relativo a questa istanza di gancio.` - } + + // firstrun: { + // basic: `Inserisci titolo e descrizione della tua istanza di gancio.`, + // database: `Gancio ha bisogno di un database postgresql!`, + // smtp: `Inserisci un account SMTP relativo a questa istanza di gancio.` + // }, + // email: { + // registration: `Abbiamo ricevuto la richiesta di registrazione. La confermeremo quanto prima.\n Ciao` + // } } export default it diff --git a/pages/add/_edit.vue b/pages/add/_edit.vue index 7472c2bf..05256f72 100644 --- a/pages/add/_edit.vue +++ b/pages/add/_edit.vue @@ -269,9 +269,9 @@ export default { await this.addEvent(formData) } this.updateMeta() - this.loading = false this.$router.replace('/') Message({ type: 'success', message: this.$auth.loggedIn ? this.$t('event.added') : this.$t('event.added_anon')}) + this.loading = false } catch (e) { this.loading = false console.error(e) diff --git a/pages/event/_id.vue b/pages/event/_id.vue index 4dc9f7a0..49f7bcc6 100644 --- a/pages/event/_id.vue +++ b/pages/event/_id.vue @@ -5,46 +5,50 @@ nuxt-link.float-right(to='/') el-button(circle icon='el-icon-close' type='danger' size='small' plain) - //- title, where, when - h5.text-center {{event.title}} - div.nextprev - nuxt-link(v-if='prev' :to='`/event/${prev.id}`') - el-button(icon='el-icon-arrow-left' round type='success') - nuxt-link.float-right(v-if='next' :to='`/event/${next.id}`') - el-button(icon='el-icon-arrow-right' round type='success') - - //- image - img(:src='imgPath' v-if='event.image_path') + div(v-if='!event') + h5 {{$t('event.not_found')}} - .info - div {{event|event_when}} - div {{event.place.name}} - {{event.place.address}} + div(v-else) + //- title, where, when + h5.text-center {{event.title}} + div.nextprev + nuxt-link(v-if='prev' :to='`/event/${prev.id}`') + el-button(icon='el-icon-arrow-left' round type='success') + nuxt-link.float-right(v-if='next' :to='`/event/${next.id}`') + el-button(icon='el-icon-arrow-right' round type='success') + + //- image + img(:src='imgPath' v-if='event.image_path') - //- description and tags - div(v-if='event.description || event.tags') - pre(v-html='event.description') - el-tag.mr-1(v-for='tag in event.tags' - size='mini' :key='tag.tag') {{tag.tag}} + .info + div {{event|event_when}} + div {{event.place.name}} - {{event.place.address}} - //- show hide, confirm, delete, edit buttons when allowed - div(v-if='mine') - hr - el-button(v-if='event.is_visible' size='mini' plain type='warning' @click.prevents='toggle' icon='el-icon-view') {{$t('common.hide')}} - el-button(v-else plain type='success' size='mini' @click.prevents='toggle' icon='el-icon-view') {{$t('common.confirm')}} - el-button(plain type='danger' size='mini' @click.prevent='remove' icon='el-icon-remove') {{$t('common.remove')}} - el-button(plain type='primary' size='mini' @click='$router.replace(`/add/${event.id}`)' icon='el-icon-edit') {{$t('common.edit')}} + //- description and tags + div(v-if='event.description || event.tags') + pre(v-html='event.description') + el-tag.mr-1(v-for='tag in event.tags' + size='mini' :key='tag.tag') {{tag.tag}} - //- comments - .card-body(v-if='event.activitypub_id') - strong {{$t('common.related')}} - - a(:href='`https://mastodon.cisti.org/web/statuses/${event.activitypub_id}`') {{$t('common.add')}} - .card-header(v-for='comment in event.comments' :key='comment.id') - img.avatar(:src='comment.data.last_status.account.avatar') - strong {{comment.author}} - a.float-right(:href='comment.data.last_status.url') - small {{comment.data.last_status.created_at|datetime}} - div.mt-1(v-html='comment_filter(comment.text)') - img(v-for='img in comment.data.last_status.media_attachments' :src='img.preview_url') + //- show hide, confirm, delete, edit buttons when allowed + div(v-if='mine') + hr + el-button(v-if='event.is_visible' size='mini' plain type='warning' @click.prevents='toggle' icon='el-icon-view') {{$t('common.hide')}} + el-button(v-else plain type='success' size='mini' @click.prevents='toggle' icon='el-icon-view') {{$t('common.confirm')}} + el-button(plain type='danger' size='mini' @click.prevent='remove' icon='el-icon-remove') {{$t('common.remove')}} + el-button(plain type='primary' size='mini' @click='$router.replace(`/add/${event.id}`)' icon='el-icon-edit') {{$t('common.edit')}} + + //- comments + .card-body(v-if='event.activitypub_id') + strong {{$t('common.related')}} - + a(:href='`https://mastodon.cisti.org/web/statuses/${event.activitypub_id}`') {{$t('common.add')}} + .card-header(v-for='comment in event.comments' :key='comment.id') + img.avatar(:src='comment.data.last_status.account.avatar') + strong {{comment.author}} + a.float-right(:href='comment.data.last_status.url') + small {{comment.data.last_status.created_at|datetime}} + div.mt-1(v-html='comment_filter(comment.text)') + img(v-for='img in comment.data.last_status.media_attachments' :src='img.preview_url')