[names] #265 move names to db
This commit is contained in:
parent
94e9c18c79
commit
de5307a01d
|
@ -0,0 +1,38 @@
|
||||||
|
<template>
|
||||||
|
<div class="d-flex flex-grow-1">
|
||||||
|
<select v-model="month" class="form-select">
|
||||||
|
<option v-for="m in 12" :value="m"><T>calendar.months.{{m}}</T></option>
|
||||||
|
</select>
|
||||||
|
<select v-model="day" class="form-select">
|
||||||
|
<option v-for="d in 31" :value="d">{{d}}</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
props: {
|
||||||
|
value: {required: true},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
const [month, day] = this.value ? this.value.split('-') : ['1', '1'];
|
||||||
|
return {
|
||||||
|
month: parseInt(month),
|
||||||
|
day: parseInt(day),
|
||||||
|
}
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
value() {
|
||||||
|
const [month, day] = this.value ? this.value.split('-') : ['1', '1'];
|
||||||
|
this.month = parseInt(month);
|
||||||
|
this.day = parseInt(day);
|
||||||
|
},
|
||||||
|
month() {
|
||||||
|
this.$emit('input', `${this.month.toString().padStart(2, '0')}-${this.day.toString().padStart(2, '0')}`)
|
||||||
|
},
|
||||||
|
day() {
|
||||||
|
this.$emit('input', `${this.month.toString().padStart(2, '0')}-${this.day.toString().padStart(2, '0')}`)
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
|
@ -169,7 +169,7 @@
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.config.names.enabled) {
|
if (this.config.names && this.config.names.enabled && this.config.names.published) {
|
||||||
links.push({
|
links.push({
|
||||||
link: '/' + this.config.names.route,
|
link: '/' + this.config.names.route,
|
||||||
icon: 'signature',
|
icon: 'signature',
|
||||||
|
|
|
@ -0,0 +1,92 @@
|
||||||
|
<template>
|
||||||
|
<LazyHydrate when-visible>
|
||||||
|
<div>
|
||||||
|
<div class="d-flex justify-content-between">
|
||||||
|
<h3>{{ name.name }}</h3>
|
||||||
|
<slot></slot>
|
||||||
|
</div>
|
||||||
|
<div class="d-flex flex-column flex-md-row">
|
||||||
|
<ul class="list-unstyled w-md-50">
|
||||||
|
<li v-if="name.origin" class="mb-2">
|
||||||
|
<Icon v="map-marked-alt"/>
|
||||||
|
<strong><T>names.origin</T>:</strong>
|
||||||
|
{{ name.origin }}
|
||||||
|
</li>
|
||||||
|
<li v-if="name.meaning" class="mb-2">
|
||||||
|
<Icon v="comment-exclamation"/>
|
||||||
|
<strong><T>names.meaning</T>:</strong>
|
||||||
|
<LinkedText :text="name.meaning"/>
|
||||||
|
</li>
|
||||||
|
<li v-if="name.usage" class="mb-2">
|
||||||
|
<Icon v="user-friends"/>
|
||||||
|
<strong><T>names.usage</T>:</strong>
|
||||||
|
{{ name.usage }}
|
||||||
|
</li>
|
||||||
|
<li v-if="config.names.legally && name.legally" class="mb-2">
|
||||||
|
<Icon v="file-contract"/>
|
||||||
|
<strong><T>names.legally</T>:</strong>
|
||||||
|
{{ name.legally }}
|
||||||
|
</li>
|
||||||
|
<li v-if="config.names.count" class="mb-2">
|
||||||
|
<Icon v="users"/>
|
||||||
|
<strong><T>names.count</T>:</strong>
|
||||||
|
<NameCount :name="name.name"/>
|
||||||
|
</li>
|
||||||
|
<li v-if="config.names.namedays && name.namedays.length">
|
||||||
|
<Icon v="glass-cheers"/>
|
||||||
|
<strong><T>names.namedays</T>:</strong>
|
||||||
|
{{ namedaysString(name) }}
|
||||||
|
<p class="small" v-if="name.namedaysComment">(<LinkedText :text="name.namedaysComment"/>)</p>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<ul class="list-unstyled w-md-50">
|
||||||
|
<li v-for="pro in name.pros" class="mb-2">
|
||||||
|
<Icon v="plus-circle"/>
|
||||||
|
<LinkedText :text="pro"/>
|
||||||
|
</li>
|
||||||
|
<li v-for="con in name.cons" class="mb-2">
|
||||||
|
<Icon v="minus-circle"/>
|
||||||
|
<LinkedText :text="con"/>
|
||||||
|
</li>
|
||||||
|
<li v-for="person in name.notablePeople" class="mb-2">
|
||||||
|
<Icon v="user"/>
|
||||||
|
<LinkedText :text="person"/>
|
||||||
|
</li>
|
||||||
|
<li v-for="link in name.links" class="mb-2">
|
||||||
|
<Icon v="external-link"/>
|
||||||
|
<a :href="link.trim()" target="_blank" rel="noopener">{{ clearUrl(link) }}</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</LazyHydrate>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {clearUrl} from '~/src/helpers';
|
||||||
|
import LazyHydrate from 'vue-lazy-hydration';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
components: { LazyHydrate },
|
||||||
|
props: {
|
||||||
|
name: {required: true},
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
clearUrl,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
namedaysString(name) {
|
||||||
|
if (!name.namedays.length) { return ''; }
|
||||||
|
|
||||||
|
const days = name.namedays.map(d => {
|
||||||
|
const [month, day] = d.split('-');
|
||||||
|
return this.$t('calendar.dates.' + parseInt(month), {day: parseInt(day)});
|
||||||
|
})
|
||||||
|
|
||||||
|
return days.join(', ')
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
|
@ -0,0 +1,177 @@
|
||||||
|
<template>
|
||||||
|
<section v-if="$user()">
|
||||||
|
<div v-if="afterSubmit" class="alert alert-success text-center">
|
||||||
|
<p>
|
||||||
|
<T>nouns.submit.thanks</T>
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
<button class="btn btn-success" @click="afterSubmit = false">
|
||||||
|
<Icon v="plus"/>
|
||||||
|
<T>nouns.submit.another</T>
|
||||||
|
</button>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
<form v-else @submit.prevent="submit">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-12 col-lg-6">
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.name</T>:</strong></label>
|
||||||
|
<input v-model="form.name" class="form-control" required/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.origin</T>:</strong></label>
|
||||||
|
<input v-model="form.origin" class="form-control"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.meaning</T>:</strong></label>
|
||||||
|
<input v-model="form.meaning" class="form-control"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.usage</T>:</strong></label>
|
||||||
|
<input v-model="form.usage" class="form-control"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group" v-if="config.names.legally">
|
||||||
|
<label><strong><T>names.legally</T>:</strong></label>
|
||||||
|
<input v-model="form.legally" class="form-control"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<template v-if="config.names.namedays">
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.namedays</T>:</strong></label>
|
||||||
|
<ListInput v-model="form.namedays" v-slot="s">
|
||||||
|
<DayMonth v-model="s.val" @input="s.update(s.val)"/>
|
||||||
|
</ListInput>
|
||||||
|
|
||||||
|
<Debug :v="form.namedays"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.namedaysComment</T>:</strong></label>
|
||||||
|
<input v-model="form.namedaysComment" class="form-control"/>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</div>
|
||||||
|
<div class="col-12 col-lg-6">
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.pros</T>:</strong></label>
|
||||||
|
<ListInput v-model="form.pros"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.cons</T>:</strong></label>
|
||||||
|
<ListInput v-model="form.cons"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.notablePeople</T>:</strong></label>
|
||||||
|
<ListInput v-model="form.notablePeople"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label><strong><T>names.links</T>:</strong></label>
|
||||||
|
<ListInput v-model="form.links" v-slot="s">
|
||||||
|
<input v-model="s.val" type="url" class="form-control" @keyup="s.update(s.val)" required/>
|
||||||
|
</ListInput>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="alert alert-info" v-if="form.base">
|
||||||
|
<Icon v="info-circle"/>
|
||||||
|
<T>nouns.editing</T>
|
||||||
|
<button class="btn btn-sm float-end" @click="form.base = null">
|
||||||
|
<Icon v="times"/>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<button class="btn btn-primary w-100" :disabled="submitting">
|
||||||
|
<template v-if="submitting">
|
||||||
|
<Icon v="circle-notch fa-spin"/>
|
||||||
|
</template>
|
||||||
|
<template v-else>
|
||||||
|
<Icon v="plus"/>
|
||||||
|
<T>nouns.submit.actionLong</T>
|
||||||
|
</template>
|
||||||
|
</button>
|
||||||
|
<p class="small text-muted mt-1"><T>nouns.submit.moderation</T></p>
|
||||||
|
</form>
|
||||||
|
</section>
|
||||||
|
<section v-else class="text-center">
|
||||||
|
<div class="alert alert-info">
|
||||||
|
<T>crud.loginRequired</T>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {
|
||||||
|
name: '',
|
||||||
|
origin: '',
|
||||||
|
meaning: '',
|
||||||
|
usage: '',
|
||||||
|
legally: '',
|
||||||
|
pros: [],
|
||||||
|
cons: [],
|
||||||
|
notablePeople: [],
|
||||||
|
links: [],
|
||||||
|
namedays: [],
|
||||||
|
namedaysComment: '',
|
||||||
|
base: null,
|
||||||
|
},
|
||||||
|
submitting: false,
|
||||||
|
afterSubmit: false,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async submit() {
|
||||||
|
this.submitting = true;
|
||||||
|
try {
|
||||||
|
await this.$post(`/names/submit`, this.form);
|
||||||
|
|
||||||
|
this.afterSubmit = true;
|
||||||
|
this.form = {
|
||||||
|
name: '',
|
||||||
|
origin: '',
|
||||||
|
meaning: '',
|
||||||
|
usage: '',
|
||||||
|
legally: '',
|
||||||
|
pros: [],
|
||||||
|
cons: [],
|
||||||
|
notablePeople: [],
|
||||||
|
links: [],
|
||||||
|
namedays: [],
|
||||||
|
namedaysComment: '',
|
||||||
|
base: null,
|
||||||
|
};
|
||||||
|
} finally {
|
||||||
|
this.submitting = false;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
edit(name) {
|
||||||
|
this.form = {
|
||||||
|
name: name.name,
|
||||||
|
origin: name.origin,
|
||||||
|
meaning: name.meaning,
|
||||||
|
usage: name.usage,
|
||||||
|
legally: name.legally,
|
||||||
|
pros: name.pros,
|
||||||
|
cons: name.cons,
|
||||||
|
notablePeople: name.notablePeople,
|
||||||
|
links: name.links,
|
||||||
|
namedays: name.namedays,
|
||||||
|
namedaysComment: name.namedaysComment,
|
||||||
|
base: name.id,
|
||||||
|
}
|
||||||
|
this.afterSubmit = false;
|
||||||
|
this.$el.scrollIntoView();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
};
|
||||||
|
</script>
|
|
@ -0,0 +1,5 @@
|
||||||
|
<template>
|
||||||
|
<ul v-if="config.links.names && config.links.names.length" class="list-unstyled">
|
||||||
|
<Link v-for="link in config.links.names" :link="link" :key="link.url"/>
|
||||||
|
</ul>
|
||||||
|
</template>
|
|
@ -46,6 +46,7 @@
|
||||||
'terms',
|
'terms',
|
||||||
'inclusive',
|
'inclusive',
|
||||||
'census',
|
'census',
|
||||||
|
'names',
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
|
@ -95,7 +95,6 @@
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: { LazyHydrate },
|
components: { LazyHydrate },
|
||||||
name: 'Source',
|
|
||||||
props: {
|
props: {
|
||||||
source: { required: true },
|
source: { required: true },
|
||||||
manage: { type: Boolean },
|
manage: { type: Boolean },
|
||||||
|
|
|
@ -112,12 +112,14 @@ terminology:
|
||||||
route: 'terminologia'
|
route: 'terminologia'
|
||||||
|
|
||||||
names:
|
names:
|
||||||
enabled: false
|
enabled: true
|
||||||
|
published: false
|
||||||
route: 'imiona'
|
route: 'imiona'
|
||||||
legally: true
|
legally: true
|
||||||
count: true
|
count: true
|
||||||
countSex: { M: 'mars', K: 'venus' }
|
countSex: { M: 'mars', K: 'venus' }
|
||||||
countOrdinal: { 1: 'pierwsze imię', 2: 'drugie imię' }
|
countOrdinal: { 1: 'pierwsze imię', 2: 'drugie imię' }
|
||||||
|
namedays: true
|
||||||
|
|
||||||
faq:
|
faq:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
@ -936,6 +938,34 @@ links:
|
||||||
url: 'http://dobrerzeczy.online/femaleSwitcher/'
|
url: 'http://dobrerzeczy.online/femaleSwitcher/'
|
||||||
headline: 'Female switcher'
|
headline: 'Female switcher'
|
||||||
extra: ' – apka, która zamieni formy fleksyjne wyświetlanych tekstów z rodzaju męskiego na żeński.'
|
extra: ' – apka, która zamieni formy fleksyjne wyświetlanych tekstów z rodzaju męskiego na żeński.'
|
||||||
|
names:
|
||||||
|
-
|
||||||
|
icon: 'pen-nib'
|
||||||
|
url: '/blog/imiona-unisex-pesel'
|
||||||
|
headline: 'Imiona „unisex” w rejestrze PESEL'
|
||||||
|
quote: >
|
||||||
|
W zależności od tego, na którą metrykę spojrzymy, najbardziej uniseksowymi imionami uznawanymi przez urzędy są:
|
||||||
|
– Maria – głównie ze względu na tradycję nadawania tego imienia chłopcom na cześć Marii z Nazaretu,
|
||||||
|
– Andrea - jeśli patrzymy tylko na pierwsze imiona,
|
||||||
|
– Dominique – z imponującym balansem 0.494, choć niezbyt popularne.
|
||||||
|
Najważniejszy wniosek jednak jest taki, że już teraz urzędy uznają całą masę imion za zgodne z ustawą niezależnie od płci metrykalnej 😉
|
||||||
|
-
|
||||||
|
icon: 'info-circle'
|
||||||
|
url: 'https://docs.google.com/document/d/1xkX0LE1EiwGqRyVFsMImmY2XnsO7f8jFUjUbUC77r6Y/edit'
|
||||||
|
headline: 'Poradnik, jak urzędowo zmienić imię w Polsce'
|
||||||
|
-
|
||||||
|
icon: 'newspaper'
|
||||||
|
url: 'https://wyborcza.pl/7,75410,26361697,prof-klosinska-dzban-to-slowo-nacechowane-pejoratywnie.html?disableRedirects=true'
|
||||||
|
headline: 'Prof. Katarzyna Kłosińska o neutralnych płciowo imionach'
|
||||||
|
quote: >
|
||||||
|
Od kilku lat coraz częściej dostajemy z urzędu stanu cywilnego prośby o opiniowanie imion neutralnych płciowo.
|
||||||
|
Najczęściej chodzi o nastolatki, których płeć biologiczna jest inna niż psychiczna,
|
||||||
|
są w trakcie procedury korekty płci lub nie identyfikują się ani jako kobieta, ani mężczyzna.
|
||||||
|
Chcą zmienić imię na takie, które nie będzie się kończyło ani na „a”, jak w polszczyźnie imiona kobiece,
|
||||||
|
ani na spółgłoskę, przypisaną imionom męskim.
|
||||||
|
Choć polska tradycja nie zna takich imion, to opiniujemy je pozytywnie,
|
||||||
|
bo w zderzeniu dwóch wartości: dobrostanu człowieka wynikającego z jego problemów z tożsamością i tradycji językowej,
|
||||||
|
należy uznać tę pierwszą za wyższą.
|
||||||
|
|
||||||
people:
|
people:
|
||||||
enabled: false
|
enabled: false
|
||||||
|
|
|
@ -1,96 +0,0 @@
|
||||||
name origin meaning usage legally cons pros notablePeople count links
|
|
||||||
Aba hebrajskie (m) {ojciec} żeńskie i męskie męskie M:14, K:5
|
|
||||||
Abi hebrajskie (k) - zdr. od Abigail radość ojca częściej żeńskie żeńskie może zostać uznane za zdrobnienie unisex końcówka M:2, K:9
|
|
||||||
Abia arabskie (k), farerskie (m) wielki (ar.) Skandynawia (m), kr. arabskie (k) unisex Abia Brown (m) M&K:0 https://www.nordicnames.de/wiki/Abia https://en.wikipedia.org/wiki/Abia_Brown
|
|
||||||
Abir arabskie (k), hebrajskie (m), bengalskie (m) zapach (ar.) Indie(m), kr. arabskie (k) unisex Abir Chatterjee (m), Abir Al-Sahlani (k) M:4, K:17 https://en.wikipedia.org/wiki/Abir_Al-Sahlani https://en.wikipedia.org/wiki/Abir_Chatterjee
|
|
||||||
Abe hebrajskie (m), zdr. od Abraham raczej męskie męskie może zostać uznane za zdrobnienie nijaka końcówka M:2, K:0 https://en.wikipedia.org/wiki/Abe_(given_name)
|
|
||||||
Adi hebrajskie, sanskryt klejnot (hebr.) unisex unisex może zostać uznane za zdrobnienie unisex końcówka Adi Ashkenazi (k), Adi Rocha (m) M:92. K: 257 https://en.wikipedia.org/wiki/Adi_(name)
|
|
||||||
Adiel hebrajskie (m) ozdoba Boga raczej męskie męskie końcówka Arielkowa M:5, K:0 https://en.wikipedia.org/wiki/Adiel
|
|
||||||
Adriel hebrajskie (m) raczej męskie męskie końcówka Arielkowa M:9, K:2
|
|
||||||
Aeron celtyckie wojna, królowa jasności unisex unisex Aeron Clement (m) M:2, K:0 https://pl.wikipedia.org/wiki/Aeron_(imi%C4%99) http://www.imiona.info/Aeron.html https://en.wikipedia.org/wiki/Aeron_Clement https://en.wikipedia.org/wiki/River_Aeron
|
|
||||||
Agam hebrajskie, hindi jezioro (hebr.) raczej męskie unisex Agam Darshi (k) M:5, K:18 https://www.babycenter.in/babyname/25050895/agam
|
|
||||||
Agi starogermańskie, greckie - zdr. od Agata, Agnes Chorwacja (m), Skandynawia (unisex), Węgry (k) unisex może zostać uznane za zdrobnienie unisex końcówka Agi Donath (k) M&K:0 https://www.behindthename.com/name/agi https://www.nordicnames.de/wiki/Agi_m https://www.nordicnames.de/wiki/Agi_f https://en.wikipedia.org/wiki/AGI
|
|
||||||
Alde wersja imienia Alda, germańskie Skandynawia(k) żeńskie nijaka końcówka M&K:0 https://www.nordicnames.de/wiki/Alde
|
|
||||||
Ale Skandynawia, języki romańskie (m) męskie może zostać uznane za zdrobnienie nijaka końcówka M:2, K:0 https://en.wikipedia.org/wiki/Ale_(disambiguation)
|
|
||||||
Aleks/Alex greckie obrończe ludu unisex żeńskie może zostać uznane za zdrobnienie, uznawane w PL za męskie Alex Wagner (k) Aleks: M:8245, K:4 Alex: M:8984, K:53 https://en.wikipedia.org/wiki/Alex_Wagner https://en.wikipedia.org/wiki/Alex#People_whose_first_name_is_Alex https://www.famousfix.com/list/celebrities-with-first-name-alex
|
|
||||||
Aleksandre greckie obrończe ludu Francja, Portugalia, Gruzja (m) męskie nijaka końcówka M:170, K:0
|
|
||||||
Alexis greckie obrończe ludu Kraje anglojęz. (uni), Grecja(m) unisex unisex końcówka Alexis Panselinos (m), Alexis Jordan (k) M:192, K:95 https://pl.wiktionary.org/wiki/Alexis https://en.wikipedia.org/wiki/Alexis_Panselinos https://en.wikipedia.org/wiki/Alexis_Jordan
|
|
||||||
Ali arabskie, ang. zdrobnienie licznych imion wysokie Kraje anglojęz. (uni), kr. arabskie(m) unisex może zostać uznane za zdrobnienie, kojarzone męsko unisex końcówka Ali Landry (k) M: 1723, K: 57 (gł. im. drugie) https://en.wikipedia.org/wiki/Ali_(name)#Given_name https://en.wikipedia.org/wiki/Ali_Landry
|
|
||||||
Alika arabskie, hawajskie, germańskie raczej żeskie unisex Alika DeRego (m) M: 14, K: 17 https://thesundevils.com/sports/baseball/roster/alika-williams/8712 https://en.wikipedia.org/wiki/Alika_DeRego
|
|
||||||
Aliki arabskie, hawajskie, germańskie raczej żeńskie unisex unisex końcówka M: 2, K: 23
|
|
||||||
Alix starofrancuskie lub greckie unisex, częściej żeńskie unisex unisex końcówka Alix Popham (m) M:2, K:27 https://en.wikipedia.org/wiki/Alix_(given_name)
|
|
||||||
Alo rdzennie amerykańskie przewodnicze duchowe męskie męskie nijaka końcówka M&K:0 https://www.names.org/n/alo/about https://themeaningofthename.com/alo/
|
|
||||||
Alte jidysz żeńskie i męskie żeńskie nijaka końcówka M&K:0 https://www.nordicnames.de/wiki/Alte https://www.kveller.com/jewish-baby-name/alte/
|
|
||||||
Alva germańskie, hebrajskie elf (ger.), jego wysokość (hebr.) unisex - Skandynawia (k), kr. anglojęz. (m) unisex Alva Mydral (k), Alva Duer (m) M:2, K:15 https://en.wikipedia.org/wiki/Alva_(given_name)
|
|
||||||
Alvard Armenia róża Armenia (k) żeńskie Alvard Petrossyan (k) M:0, K:33 https://en.wikipedia.org/wiki/Alvard_Petrossyan
|
|
||||||
Alvi farerskie elf, siła (far.) Skandynawia(uni), kraje arabskie i Azja Pd-Wsch(m) unisex unisex końcówka M:14, K:0 https://www.nordicnames.de/wiki/Alvi_m https://www.nordicnames.de/wiki/Alvi_f
|
|
||||||
Amare różne po łacinie znaczy kochać unisex unisex nijaka końcówka Amare Stoudemire (m) M:3:, K:0 https://nameberry.com/babyname/Amare https://pl.wikipedia.org/wiki/Amar%E2%80%99e_Stoudemire https://www.babynames.com/name/amare https://family.disney.com/baby-names/unisex-names/meaning-of-amare/ https://www.babynamespedia.com/meaning/Amare/f
|
|
||||||
Amari sanskryt, afrykańskie raczej męskie męskie unisex końcówka Amari Morgan-Smith (m) M&K:0 https://www.pampers.com/en-us/pregnancy/baby-names/find-your-baby-name/boys-names/amari https://en.wikipedia.org/wiki/Amari_Morgan-Smith https://nameberry.com/babyname/Amari/girl
|
|
||||||
Amel arabskie nadzieja unisex, kr. arabskie (k) unisex Amel Senan (k), Amel Tuka (m) M:11, K:62 https://en.wikipedia.org/wiki/Amel_(name)
|
|
||||||
Ami hebrajskie, indyjskie, japońskie nektar (ind), warte zaufania (hebr) unisex, Japonia (k) unisex unisex końcówka Ami Miron (m), Ami Trivedi (k) M:14, K: 12 https://en.wikipedia.org/wiki/Ami_(given_name)
|
|
||||||
Amparo Hiszpania schronienie żeńskie żeńskie nijaka końcówka M:0, K:6 https://pl.wikipedia.org/wiki/Amparo https://en.wikipedia.org/wiki/Amparo_(name)
|
|
||||||
Anael hebrajskie w żydowskiej tradycji imię archanioła unisex żeńskie kojarzy się z wiadomo czym Anael Lardy (k) M:0, K:4 https://www.kveller.com/jewish-baby-name/anael/ https://playback.fm/people/first-name/ana%C3%ABl https://www.behindthename.com/name/anael/submitted
|
|
||||||
Andi greckie, zdr. od Andrew/Andrea odważne, męskie unisex unisex unisex końcówka Andi Osho (k), Andy Allo (k) M:14, K:0; Andy: M:128, K:0 https://en.wikipedia.org/wiki/Andy_(given_name)
|
|
||||||
Andrea greckie, Włochy odważne, męskie Włochy, Albania (m), gdzie indziej raczej (k) unisex Andrea Bocelli (m) M:648, K: 1942 https://en.wikipedia.org/wiki/Andrea
|
|
||||||
Angel greckie {anielę}, {posłańcze} kraje anglojęz. (uni), kr. hiszpańskojęz. (m) unisex Angel Faith (k), Angel Rubio (m) M:379, K:66 https://en.wikipedia.org/wiki/Angel_(given_name)
|
|
||||||
Anri różne Japonia (unisex), Gruzja, Azerbejdżan (m) unisex unisex końcówka Anri Sala (m), Anri du Toit (ps.Yolandi Visser) (k) M:9, K:2 https://en.wikipedia.org/wiki/Anri_(given_name) https://en.wikipedia.org/wiki/Yolandi_Visser
|
|
||||||
Ante łacińskie Antoniusz, greckie Andreas Chorwacja, Szwecja, Litwa (m) męskie nijaka końcówka M:16, K:0 https://en.wikipedia.org/wiki/Ante_(name)
|
|
||||||
Apo finśkie zdrobnienia różnych imion Finlandia (unisex) unisex nijaka końcówka Apo Avedissian (m) M&K:0 https://www.babynamesdirect.com/boy/apo https://www.babynamesdirect.com/girl/apo https://www.nordicnames.de/wiki/Apo_m https://www.nordicnames.de/wiki/Apo_f https://en.wikipedia.org/wiki/Apo_Avedissian
|
|
||||||
Archie/Arczi germańskie, zdr. od Archibld raczej męskie unisex unisex końcówka Archie Panjabi (k) M: 32, K: 0 https://en.wikipedia.org/wiki/Archie_Panjabi https://en.wikipedia.org/wiki/Archie
|
|
||||||
Arda tureckie, armeńskie, staroangielskie berło (tur) Turcja (m), Armenia (k) unisex Arda Turan (m) M:55, K:0 https://en.wikipedia.org/wiki/Arda_(name)
|
|
||||||
Areli hebrajskie lew Boga raczej męskie męskie unisex końcówka M&K:0 https://www.babynames.com/name/areli https://www.behindthename.com/name/areli
|
|
||||||
Ari germańskie, greckie, hebrajskie orzeł (ger), szlachetne (gr), lew(hebr). m lub k w zależności od języka unisex może zostać uznane za zdrobnienie unisex końcówka Ari Meyers (k) M:104, K:4 https://en.wikipedia.org/wiki/Ari_(name)
|
|
||||||
Aria/Arja/Arya perskie, hebrajskie lwica (hebr., szlachetne (per), powietrze (wł), złoto (alb) Indie(m/k), Izrael(k), perski (m) unisex Aria Shahghasemi (m) Aria: M:15, K:120, Arja: M:2, K:9, Arya: M:10, K:39 https://en.wikipedia.org/wiki/Aria_(name) https://www.filmweb.pl/person/Aria+Shahghasemi-2592084
|
|
||||||
Ariel hebrajskie lew Boga unisex, dawniej męskie unisex końcówka Arielkowa Ariel Winter (k) M:6151, F: 76 https://en.wikipedia.org/wiki/Ariel_(name) https://en.wikipedia.org/wiki/Ariel_Winter
|
|
||||||
Aris greckie bóg Ares/szlachetne raczej męskie, Skandynawia (unisex) unisex nowogrecka męska końcówka zbieżna ze starogrecką żenską (por. Artemis, Eris) M:47:, F:2 https://www.nordicnames.de/wiki/Aris_f https://www.nordicnames.de/wiki/Aris_m https://en.wikipedia.org/wiki/Aris
|
|
||||||
Artemis greckie bogini Artemida raczej żeńskie, rzadziej męskie unisex końcowka unisex Artemis Fowl (m, fikcyjna) M:3, K:33 https://en.wiktionary.org/wiki/Artemis https://pl.wikipedia.org/wiki/Artemis_Fowl
|
|
||||||
Arti sanksryt żeńskie żeńskie może zostać uznane za zdrobnienie nijaka końcówka M:2, K:9 https://en.wikipedia.org/wiki/Arti_(given_name)
|
|
||||||
Arto celtyckie Finlandia (m) męskie może zostać uznane za zdrobnienie nijaka końcówka Arto Salomaa M:5, K:0 https://www.nordicnames.de/wiki/Arto https://www.behindthename.com/name/arto https://en.wikipedia.org/wiki/Arto_Salomaa
|
|
||||||
Asa hebrajskie, japońskie, afrykańskie unisex unisex Asa Briggs (m) M:5, K:2 https://en.wikipedia.org/wiki/Asa_(name)
|
|
||||||
Asel arabskie słodkie żeńskie żeńskie M:0, K:13 https://www.behindthename.com/name/asel
|
|
||||||
Assol/Asol rosyjskie żeńskie żeńskie Asol Sliwiec (k) M&K:0 https://pl.wikipedia.org/wiki/Assol_(imi%C4%99) https://pl.wikipedia.org/wiki/Asol_Sliwiec
|
|
||||||
Ata arabskie, tureckie prezent (ar), przodek (tur) męskie męskie Ata Demirer (m) M:27, K:4 https://en.wikipedia.org/wiki/Ata_(name)
|
|
||||||
Audre staroangielskie żeńskie żeńskie nijaka końcówka Audre, postać z Korony Królów (k), Audre Lorde (k) M&K:0 https://en.wikipedia.org/wiki/Audre_Lorde
|
|
||||||
Auge greckie (mitologia) promień słońca żeńskie, jeden z wariantów męskiego Auger (fr) żeńskie nijaka końcówka M&K:0 https://www.familyeducation.com/baby-names/name-meaning/auge
|
|
||||||
Aulani hawajskie posłańcze króla raczej żeńskie żeńskie nazywa się tak kurort Disneya na Hawajach unisex końcówka M&K:0 https://www.mynamestats.com/First-Names/A/AU/AULANI/index.html
|
|
||||||
Auri greckie, od Aura lub lacińskie, od Aurora bryza (gr), świt (łac) raczej żeńskie unisex unisex końcówka Auri Dias Faustino (m) M:0, K:3 https://www.nordicnames.de/wiki/Auri https://en.wikipedia.org/wiki/Auri_Dias_Faustino
|
|
||||||
Aurum łacina zloto unisex unisex końcówka nijaka M&K:0 https://www.babynames.com/name/aurum https://themeaningofthename.com/aurum/
|
|
||||||
Awo/Avo afrykańskie, grenlandzkie urodzone we wtorek (afr) unisex unisex końcówka nijaka M&K:0 https://www.name-doctor.com/name-awo-meaning-of-awo-42887.html https://www.nordicnames.de/wiki/Avo https://en.wikipedia.org/wiki/Avo_(name)
|
|
||||||
Aza kurdyjskie (m), starocerkiewnosłowiańskie (k), arabskie (ż) odważne, hero (kurd) męskie, ale np. w krajach afrykańskich i Rosji żeńskie unisex Aza, władca Manny (m, VIII/VII w p.n.e.) M:0, K:32 https://en.wikipedia.org/wiki/Aza https://charlies-names.com/en/aza/ https://en.wikipedia.org/wiki/Mannaeans
|
|
||||||
Basanta hindi wiosna męskie męskie Basanta Regmi (m) M: 8, K:0 http://www.namepedia.org/en/firstname/Basanta/ http://www.babynology.com/assamese-mcelebritybasanta.html
|
|
||||||
Bel romańskie piękne żeńskie żeńskie może zostać uznane za zdrobnienie Annabel "Bel" Linquist (k) M&K:0 https://en.wikipedia.org/wiki/Bel_(name) http://www.namepedia.org/en/firstname/Bel/
|
|
||||||
Bela węgierskie, romańskie serce (węg), czyste (cz) Węgry (m), Czechy (k) unisex może zostać uznane za zdrobnienie liczni władcy węgier (m), Běla Hlaváčková (k) M:18, K:50 https://en.wikipedia.org/wiki/B%C4%9Bla https://en.wikipedia.org/wiki/B%C3%A9la_(given_name)
|
|
||||||
Beni romańskie dobre Japonia (k), Albania (k), Europa (m) unisex może zostać uznane za zdrobnienie unisex końcówka Beni Takemata (k) M:14, K:0 https://en.wikipedia.org/wiki/Beni http://namepedia.org/en/firstname/Beni/ https://en.wikipedia.org/wiki/Beni_Takemata
|
|
||||||
Berni germańskie, greckie niedźwiedź (ger), przynoszące zwycięstwo (gr) Skandynawia (m), kraje anglosaskie (uni) unisex może zostać uznane za zdrobnienie unisex końcówka M&K:0 https://nameberry.com/babyname/Berni https://www.nordicnames.de/wiki/Berni http://www.thinkbabynames.com/meaning/0/Berni http://namepedia.org/en/firstname/Berni/
|
|
||||||
Berno germańskie niedźwiedź męskie męskie nijaka końcówka M:5, K:0 https://www.nordicnames.de/wiki/Berno https://en.wikipedia.org/wiki/Berno
|
|
||||||
Bessi farerskie, romańskie (jako wariant Beatrice) Skandynawia (m), kraje anglosaskie (k) unisex może zostać uznane za zdrobnienie unisex końcówka M&K:0 https://www.nordicnames.de/wiki/Bessi_m https://www.nordicnames.de/wiki/Bessi_f https://nameberry.com/babyname/Bessi
|
|
||||||
Biel hebrajskie (od Gabriel) raczej męskie męskie może zostać uznane za zdrobnienie końcówka Arielkowa Biel Medina (m) M:2, K:0 https://en.wikipedia.org/wiki/Biel_(name)
|
|
||||||
Billi/Billie/Billy/Billy staroangielskie unisex żeńskie może zostać uznane za zdrobnienie unisex końcówka Billy: M:25, K:3 Billie: M&K:0, Billi: M:2, K:0, Bili: M:0, K:2 https://charlies-names.com/en/billi/ http://www.thinkbabynames.com/meaning/0/Billi https://nameberry.com/babyname/Billi https://en.wikipedia.org/wiki/Billie
|
|
||||||
Bora greckie, koreańskie wiatr Boreasz Turcja (m), Korea (ż) unisex M:39, K:0 https://en.wikipedia.org/wiki/Bora_(Korean_name)
|
|
||||||
Bori od Barbara lub Borys unisex unisex może zostać uznane za zdrobnienie unisex końcówka M:2, K:0 http://www.namepedia.org/en/firstname/Bori_(296491)/ http://www.namepedia.org/en/firstname/Bori_(105874)/ https://www.babycenter.com/baby-names-bori-438485.htm
|
|
||||||
Boro od Barbara lub Borys Węgry (k), Chorwacja (m) unisex może zostać uznane za zdrobnienie nijaka końcówka M:2,K:0 http://www.namepedia.org/en/firstname/Bor%C3%B3/, https://en.wikipedia.org/wiki/Bora_(Turkish_name)
|
|
||||||
Bri celtyckie szlachetne raczej żeńskie żeńskie może zostać uznane za zdrobnienie unisex końcówka Brie Bella (k) M&K:0 http://www.thinkbabynames.com/meaning/0/Bri http://www.thinkbabynames.com/meaning/1/Bri
|
|
||||||
Bronwyn celtyckie jasna pierś raczej żeńskie, ale -wyn to męska walijska końcówka żeńskie M:0, K:6 https://en.wikipedia.org/wiki/Bronwynn
|
|
||||||
Bruni staronordyckie Dania (m) męskie unisex końcówka M&K:0 https://www.nordicnames.de/wiki/Bruni
|
|
||||||
Bryn/Brynn celtyckie wzgórze raczej żeńskie, ale unisex unisex Bryn Renner (m) M:5, K:0 https://nameberry.com/babyname/Bryn/girl https://nameberry.com/babyname/Bryn/boy
|
|
||||||
Cameron celtyckie unisex unisex Cameron Diaz (k), Cameron Boyce (m) M:86, K:9 https://en.wikipedia.org/wiki/Cameron_(given_name)
|
|
||||||
Carrigan celtyckie włócznia raczej żeńskie żeńskie często występuje jako nazwisko M&K:0 https://www.babynames.com/name/carrigan https://www.names.org/n/carrigan/about
|
|
||||||
Charlie angielskie unisex unisex w Polsce kojarzy się głównie męsko M:149, K:16 https://en.wikipedia.org/wiki/Charlie_(given_name)
|
|
||||||
Chris/Kris greckie głównie męskie, ale używane także żeńsko unisex w Polsce kojarzy się głównie męsko Chris Evert (k) Chris: M:186, K:0, Kris: M:84, K:0 https://en.wikipedia.org/wiki/Chris_Evert
|
|
||||||
Dali Islandia (m), Hiszpania (f), najczęściej żeńskie unisex unisex końcówka Dali Jazi (m), Dali(k, bogini gruzińska) M:2, K:16 https://en.wikipedia.org/wiki/Dali_Jazi https://pl.wikipedia.org/wiki/Dali_(mitologia)
|
|
||||||
Dani hebrajskie unisex unisex unisex końcówka M:45, K:4 https://en.wikipedia.org/wiki/Dani
|
|
||||||
Darien perskie unisex, częściej męskie unisex Darien Fenton (k), Darien Ferrer (m) M:4, K:0 https://en.wikipedia.org/wiki/Darien
|
|
||||||
Datuna hebrajskie gruzińskie zdrobnienie Dawid, męskie męskie Datuna Rakviashvili (m) M:12, K:0 https://en.wikipedia.org/wiki/Datuna
|
|
||||||
Dejno greckie mitologiczne, jedna z Forkid/Grai żeńskie nijaka końcowka M&K:0 https://pl.wikipedia.org/wiki/Forkidy
|
|
||||||
Del romańskie raczej męskie unisex Del Harisson (fk M&K:0 https://en.wikipedia.org/wiki/Del_(disambiguation)
|
|
||||||
Demi greckie od Demeter raczej żeńskie żeńskie unisex końcówka Demi Orimoloye (m) M:0, K:28 https://en.wikipedia.org/wiki/Demi https://en.wikipedia.org/wiki/Demi_Orimoloye
|
|
||||||
Deo łacińskie, hindu boskie raczej męskie męskie może zostać uznane za zdrobnienie nijaka końcówka Deo Simcox (m), M:4, K:0 https://www.familyeducation.com/baby-names/name-meaning/deo http://www.namepedia.org/en/firstname/Deo/ https://www.imdb.com/name/nm2351086/
|
|
||||||
Diamanto greckie diament raczej żeńskie unisex nijaka końcówka M&K:0 https://www.behindthename.com/name/diamanto https://en.wikipedia.org/wiki/Diamond_(given_name)
|
|
||||||
Dido greckie raczej żeńskie (Dido mitologiczna) żeńskie nijaka końcówka Dido Fontana (m), Dido Miles (k) M&K:0 https://en.wikipedia.org/wiki/Dido_(disambiguation)
|
|
||||||
Dima rosyjskie, arabskie męskie (ros.), żeńskie (ar.) unisex unisex końcówka M:25, K:18 https://www.babynames.com/name/dima https://www.nordicnames.de/wiki/Dima_f https://www.nordicnames.de/wiki/Dima_m
|
|
||||||
Dimi greckie od Demeter żeńskie (gr), męskie (ros.) unisex M&K:0 https://www.behindthename.com/name/dimi
|
|
||||||
Dori greckie prezent raczej męskie, ale też jako zdr. od Dorota unisex może zostać uznane za zdrobnienie unisex końcówka Dori Seda (k), Dori Arad (m) M:11, K:0 http://www.namepedia.org/en/firstname/Dori/ https://en.wikipedia.org/wiki/Dori
|
|
||||||
Dorin/Doreen greckie prezent kr. anglojęz. (k), Rumunia (m) unisex Dorin Tudoran (m) Dorin: M:87, K:6 (Doreen 26) http://www.namepedia.org/en/firstname/Dorin/ https://en.wikipedia.org/wiki/Doreen_(given_name) https://en.wikipedia.org/wiki/Dorin
|
|
||||||
Dorian greckie doryckie zwykle męskie, coraz częściej unisex męskie/unisex Dorian Gray(k), Dorian Electra (nb) M:8182, K:0 https://en.wikipedia.org/wiki/Dorian_(name) https://en.wikipedia.org/wiki/Dorian_Gray_(actress)
|
|
||||||
Doro greckie prezent Włochy, Serbia (m), kraje anglojęzyczne (k) unisex może zostać uznane za zdrobnienie nijaka końcówka Doro (k) M&K:0 http://www.namepedia.org/en/firstname/%C4%90oro/ https://pl.wikipedia.org/wiki/Doro
|
|
||||||
Duri koreańskie unisex unisex unisex końcówka M&K:0 https://en.wikipedia.org/wiki/Duri_(name)
|
|
Can't render this file because it has a wrong number of fields in line 2.
|
|
@ -422,17 +422,19 @@ names:
|
||||||
intro:
|
intro:
|
||||||
- >
|
- >
|
||||||
Przedstawiamy słownik neutralnych płciowo imion wraz z przydatnymi informacjami na ich temat.
|
Przedstawiamy słownik neutralnych płciowo imion wraz z przydatnymi informacjami na ich temat.
|
||||||
- >
|
name: 'Imię'
|
||||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
|
|
||||||
Pellentesque vel tellus fringilla, sodales ex lobortis, congue nisl.
|
|
||||||
Vivamus non magna et nibh egestas maximus quis vel urna. Ut tristique nunc vel mollis fermentum.
|
|
||||||
Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia curae;
|
|
||||||
Cras vel suscipit diam. Nunc sem lacus, dignissim rutrum libero a, gravida euismod neque.
|
|
||||||
origin: 'Pochodzenie'
|
origin: 'Pochodzenie'
|
||||||
meaning: 'Znaczenie'
|
meaning: 'Znaczenie'
|
||||||
usage: 'Użycie'
|
usage: 'Użycie'
|
||||||
legally: 'USC może uznać za'
|
legally: 'USC może uznać za'
|
||||||
count: 'Osób w rejestrze PESEL'
|
count: 'Osób w rejestrze PESEL'
|
||||||
|
namedays: 'Imieniny'
|
||||||
|
nameday: 'Imieniny'
|
||||||
|
namedaysComment: 'Skąd taka data imienin?'
|
||||||
|
links: 'Linki'
|
||||||
|
pros: 'Zalety'
|
||||||
|
cons: 'Wady'
|
||||||
|
notablePeople: 'Znane osoby'
|
||||||
empty: 'Nie znaleziono imion spełniających podane kryterium.'
|
empty: 'Nie znaleziono imion spełniających podane kryterium.'
|
||||||
|
|
||||||
faq:
|
faq:
|
||||||
|
|
File diff suppressed because one or more lines are too long
182
routes/names.vue
182
routes/names.vue
|
@ -7,6 +7,7 @@
|
||||||
|
|
||||||
<section>
|
<section>
|
||||||
<T>names.intro</T>
|
<T>names.intro</T>
|
||||||
|
<NamesLinks/>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section class="sticky-top">
|
<section class="sticky-top">
|
||||||
|
@ -18,63 +19,65 @@
|
||||||
<button v-if="filter" class="btn btn-outline-danger" @click="filter = ''; $refs.filter.focus()">
|
<button v-if="filter" class="btn btn-outline-danger" @click="filter = ''; $refs.filter.focus()">
|
||||||
<Icon v="times"/>
|
<Icon v="times"/>
|
||||||
</button>
|
</button>
|
||||||
|
<button class="btn btn-outline-success" @click="$refs.form.$el.scrollIntoView({block: 'center'})">
|
||||||
|
<Icon v="plus-circle"/>
|
||||||
|
<T>nouns.submit.action</T>
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section>
|
<section>
|
||||||
<ul class="list-group small">
|
<ul class="list-group small">
|
||||||
<template v-if="visibleNames().length">
|
<template v-if="visibleNames().length">
|
||||||
<li v-for="name in visibleNames()" class="list-group-item">
|
<li v-for="name in visibleNames()" :class="['list-group-item', name.approved ? '' : 'marked']">
|
||||||
<h3>
|
<Name :name="name">
|
||||||
{{ name.name }}
|
<ul class="list-inline small">
|
||||||
</h3>
|
<template v-if="$isGranted('names')">
|
||||||
<div class="d-flex flex-column flex-md-row">
|
<li v-if="name.author" class="list-inline-item small">
|
||||||
<ul class="list-unstyled w-md-50">
|
<nuxt-link :to="`/@${name.author}`" class="btn btn-outline-dark btn-sm">
|
||||||
<li v-if="name.origin" class="my-1">
|
<Icon v="user"/>
|
||||||
<Icon v="map-marked-alt"/>
|
<span class="btn-label">
|
||||||
<strong><T>names.origin</T>:</strong>
|
<T>crud.author</T>:
|
||||||
{{ name.origin }}
|
@{{name.author}}
|
||||||
</li>
|
</span>
|
||||||
<li v-if="name.meaning" class="my-1">
|
</nuxt-link>
|
||||||
<Icon v="comment-exclamation"/>
|
</li>
|
||||||
<strong><T>names.meaning</T>:</strong>
|
<li v-if="!name.approved" class="list-inline-item">
|
||||||
<LinkedText :text="name.meaning"/>
|
<button class="btn btn-success btn-sm" @click="approve(name)">
|
||||||
</li>
|
<Icon v="check"/>
|
||||||
<li v-if="name.usage" class="my-1">
|
<span class="btn-label"><T>crud.approve</T></span>
|
||||||
<Icon v="user-friends"/>
|
</button>
|
||||||
<strong><T>names.usage</T>:</strong>
|
</li>
|
||||||
{{ name.usage }}
|
<li v-else @click="hide(name)" class="list-inline-item">
|
||||||
</li>
|
<button class="btn btn-outline-secondary btn-sm">
|
||||||
<li v-if="config.names.legally && name.legally" class="my-1">
|
<Icon v="times"/>
|
||||||
<Icon v="file-contract"/>
|
<span class="btn-label"><T>crud.hide</T></span>
|
||||||
<strong><T>names.legally</T>:</strong>
|
</button>
|
||||||
{{ name.legally }}
|
</li>
|
||||||
</li>
|
<li class="list-inline-item">
|
||||||
<li v-if="config.names.count && name.count" class="my-1">
|
<button class="btn btn-outline-danger btn-sm" @click="remove(name)">
|
||||||
<Icon v="users"/>
|
<Icon v="trash"/>
|
||||||
<strong><T>names.count</T>:</strong>
|
<span class="btn-label"><T>crud.remove</T></span>
|
||||||
<NameCount :name="name.name"/>
|
</button>
|
||||||
|
</li>
|
||||||
|
</template>
|
||||||
|
<li class="list-inline-item">
|
||||||
|
<button class="btn btn-outline-primary btn-sm" @click="edit(name)">
|
||||||
|
<Icon v="pen"/>
|
||||||
|
<span class="btn-label">
|
||||||
|
<T v-if="$isGranted('names')">crud.edit</T>
|
||||||
|
<T v-else>nouns.edit</T>
|
||||||
|
</span>
|
||||||
|
</button>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<ul class="list-unstyled w-md-50">
|
</Name>
|
||||||
<li v-for="pro in name.pros" class="my-1">
|
|
||||||
<Icon v="plus-circle"/>
|
<small v-if="name.base && names[name.base]">
|
||||||
{{ pro }}
|
<hr/>
|
||||||
</li>
|
<p><strong><T>nouns.edited</T>:</strong></p>
|
||||||
<li v-for="con in name.cons" class="my-1">
|
<Name :name="names[name.base]"/>
|
||||||
<Icon v="minus-circle"/>
|
</small>
|
||||||
{{ con }}
|
|
||||||
</li>
|
|
||||||
<li v-for="person in name.notablePeople" class="my-1">
|
|
||||||
<Icon v="user"/>
|
|
||||||
{{ person }}
|
|
||||||
</li>
|
|
||||||
<li v-for="link in name.links" class="my-1">
|
|
||||||
<Icon v="external-link"/>
|
|
||||||
<a :href="link.trim()" target="_blank" rel="noopener">{{ clearUrl(link) }}</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</li>
|
</li>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
|
@ -86,39 +89,92 @@
|
||||||
</ul>
|
</ul>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<ScrollButton/>
|
<Separator icon="plus"/>
|
||||||
|
|
||||||
|
<section class="px-3">
|
||||||
|
<NameSubmitForm ref="form" style="scroll-padding-top: 2rem;"/>
|
||||||
|
</section>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { names } from '~/src/data';
|
import {head, buildDict} from '~/src/helpers';
|
||||||
import { head, clearUrl } from '~/src/helpers';
|
|
||||||
import hash from "../plugins/hash";
|
import hash from "../plugins/hash";
|
||||||
|
import {Name} from "../src/classes";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
mixins: [ hash ],
|
mixins: [ hash ],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
names,
|
|
||||||
clearUrl,
|
|
||||||
filter: '',
|
filter: '',
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
async asyncData({app}) {
|
||||||
|
return {
|
||||||
|
namesRaw: await app.$axios.$get(`/names`),
|
||||||
|
}
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.handleHash('', filter => {
|
this.handleHash('', filter => {
|
||||||
this.filter = filter;
|
this.filter = filter;
|
||||||
this.$refs.filter.focus();
|
if (filter) {
|
||||||
this.$refs.filter.scrollIntoView();
|
this.$refs.filter.focus();
|
||||||
setTimeout(_ => {
|
|
||||||
this.$refs.filter.scrollIntoView();
|
this.$refs.filter.scrollIntoView();
|
||||||
}, 1000);
|
setTimeout(_ => {
|
||||||
|
this.$refs.filter.scrollIntoView();
|
||||||
|
}, 1000);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
computed: {
|
||||||
|
names() {
|
||||||
|
if (this.namesRaw === undefined) {
|
||||||
|
return {};
|
||||||
|
}
|
||||||
|
|
||||||
|
return buildDict(function* (that) {
|
||||||
|
const sorted = that.namesRaw.sort((a, b) => {
|
||||||
|
if (a.approved && !b.approved) {
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
if (!a.approved && b.approved) {
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
return a.name.toLowerCase().localeCompare(b.name.toLowerCase());
|
||||||
|
});
|
||||||
|
for (let n of sorted) {
|
||||||
|
yield [n.id, new Name(n)];
|
||||||
|
}
|
||||||
|
}, this);
|
||||||
|
},
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
visibleNames() {
|
visibleNames() {
|
||||||
return Object.values(this.names)
|
return Object.values(this.names).filter(n => n.matches(this.filter));
|
||||||
.filter(n => n.matches(this.filter))
|
},
|
||||||
.sort((a, b) => a.name.localeCompare(b.name));
|
edit(name) {
|
||||||
|
this.$refs.form.edit(name);
|
||||||
|
},
|
||||||
|
async approve(name) {
|
||||||
|
await this.$post(`/names/approve/${name.id}`);
|
||||||
|
if (name.base) {
|
||||||
|
delete this.names[name.base];
|
||||||
|
}
|
||||||
|
name.approved = true;
|
||||||
|
name.base = null;
|
||||||
|
this.$forceUpdate();
|
||||||
|
},
|
||||||
|
async hide(name) {
|
||||||
|
await this.$post(`/names/hide/${name.id}`);
|
||||||
|
name.approved = false;
|
||||||
|
this.$forceUpdate();
|
||||||
|
},
|
||||||
|
async remove(name) {
|
||||||
|
await this.$confirm(this.$t('crud.removeConfirm'), 'danger');
|
||||||
|
|
||||||
|
await this.$post(`/names/remove/${name.id}`);
|
||||||
|
delete this.names[name.id];
|
||||||
|
this.$forceUpdate();
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
|
@ -143,4 +199,8 @@
|
||||||
width: 50%;
|
width: 50%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.list-group-item.marked {
|
||||||
|
border-inline-start: 3px solid $primary;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -36,8 +36,6 @@
|
||||||
<!-- TODO <SourceList v-if="person.sources.length" :names="person.sources"/> -->
|
<!-- TODO <SourceList v-if="person.sources.length" :names="person.sources"/> -->
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<ScrollButton/>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
|
@ -95,6 +95,7 @@ app.use(require('./routes/inclusive').default);
|
||||||
app.use(require('./routes/terms').default);
|
app.use(require('./routes/terms').default);
|
||||||
app.use(require('./routes/pronounce').default);
|
app.use(require('./routes/pronounce').default);
|
||||||
app.use(require('./routes/census').default);
|
app.use(require('./routes/census').default);
|
||||||
|
app.use(require('./routes/names').default);
|
||||||
|
|
||||||
app.use(require('./routes/images').default);
|
app.use(require('./routes/images').default);
|
||||||
app.use(require('./routes/blog').default);
|
app.use(require('./routes/blog').default);
|
||||||
|
|
|
@ -0,0 +1,111 @@
|
||||||
|
import { Router } from 'express';
|
||||||
|
import SQL from 'sql-template-strings';
|
||||||
|
import {ulid} from "ulid";
|
||||||
|
import {handleErrorAsync, isTroll} from "../../src/helpers";
|
||||||
|
import { caches } from "../../src/cache";
|
||||||
|
|
||||||
|
const approve = async (db, id) => {
|
||||||
|
const { base_id } = await db.get(SQL`SELECT base_id FROM names WHERE id=${id}`);
|
||||||
|
if (base_id) {
|
||||||
|
await db.get(SQL`
|
||||||
|
UPDATE names
|
||||||
|
SET deleted=1
|
||||||
|
WHERE id = ${base_id}
|
||||||
|
`);
|
||||||
|
}
|
||||||
|
await db.get(SQL`
|
||||||
|
UPDATE names
|
||||||
|
SET approved = 1, base_id = NULL
|
||||||
|
WHERE id = ${id}
|
||||||
|
`);
|
||||||
|
await caches.names.invalidate();
|
||||||
|
}
|
||||||
|
|
||||||
|
const router = Router();
|
||||||
|
|
||||||
|
router.get('/names', handleErrorAsync(async (req, res) => {
|
||||||
|
return res.json(await caches.names.fetch(async () => {
|
||||||
|
return await req.db.all(SQL`
|
||||||
|
SELECT n.*, u.username AS author FROM names n
|
||||||
|
LEFT JOIN users u ON n.author_id = u.id
|
||||||
|
WHERE n.locale = ${global.config.locale}
|
||||||
|
AND n.deleted = 0
|
||||||
|
AND n.approved >= ${req.isGranted('names') ? 0 : 1}
|
||||||
|
ORDER BY n.approved, n.name
|
||||||
|
`)
|
||||||
|
}, !req.isGranted('names')));
|
||||||
|
}));
|
||||||
|
|
||||||
|
router.post('/names/submit', handleErrorAsync(async (req, res) => {
|
||||||
|
if (!req.user) {
|
||||||
|
res.status(401).json({error: 'Unauthorised'});
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!(req.user && req.user.admin) && isTroll(JSON.stringify(req.body))) {
|
||||||
|
return res.json('ok');
|
||||||
|
}
|
||||||
|
|
||||||
|
const id = ulid();
|
||||||
|
await req.db.get(SQL`
|
||||||
|
INSERT INTO names (id, name, locale, origin, meaning, usage, legally, pros, cons, notablePeople, links, namedays, namedaysComment, deleted, approved, base_id, author_id)
|
||||||
|
VALUES (
|
||||||
|
${id},
|
||||||
|
${req.body.name}, ${global.config.locale},
|
||||||
|
${req.body.origin || null}, ${req.body.meaning || null}, ${req.body.usage || null}, ${req.body.legally || null},
|
||||||
|
${req.body.pros.length ? req.body.pros.join('|') : null}, ${req.body.cons.length ? req.body.cons.join('|') : null},
|
||||||
|
${req.body.notablePeople.length ? req.body.notablePeople.join('|') : null}, ${req.body.links.length ? req.body.links.join('|') : null},
|
||||||
|
${req.body.namedays.length ? req.body.namedays.join('|') : null}, ${req.body.namedaysComment || null},
|
||||||
|
0, 0, ${req.body.base}, ${req.user ? req.user.id : null}
|
||||||
|
)
|
||||||
|
`);
|
||||||
|
|
||||||
|
if (req.isGranted('names')) {
|
||||||
|
await approve(req.db, id);
|
||||||
|
}
|
||||||
|
|
||||||
|
return res.json('ok');
|
||||||
|
}));
|
||||||
|
|
||||||
|
router.post('/names/hide/:id', handleErrorAsync(async (req, res) => {
|
||||||
|
if (!req.isGranted('names')) {
|
||||||
|
res.status(401).json({error: 'Unauthorised'});
|
||||||
|
}
|
||||||
|
|
||||||
|
await req.db.get(SQL`
|
||||||
|
UPDATE names
|
||||||
|
SET approved = 0
|
||||||
|
WHERE id = ${req.params.id}
|
||||||
|
`);
|
||||||
|
|
||||||
|
await caches.names.invalidate();
|
||||||
|
|
||||||
|
return res.json('ok');
|
||||||
|
}));
|
||||||
|
|
||||||
|
router.post('/names/approve/:id', handleErrorAsync(async (req, res) => {
|
||||||
|
if (!req.isGranted('names')) {
|
||||||
|
res.status(401).json({error: 'Unauthorised'});
|
||||||
|
}
|
||||||
|
|
||||||
|
await approve(req.db, req.params.id);
|
||||||
|
|
||||||
|
return res.json('ok');
|
||||||
|
}));
|
||||||
|
|
||||||
|
router.post('/names/remove/:id', handleErrorAsync(async (req, res) => {
|
||||||
|
if (!req.isGranted('names')) {
|
||||||
|
res.status(401).json({error: 'Unauthorised'});
|
||||||
|
}
|
||||||
|
|
||||||
|
await req.db.get(SQL`
|
||||||
|
UPDATE names
|
||||||
|
SET deleted=1
|
||||||
|
WHERE id = ${req.params.id}
|
||||||
|
`);
|
||||||
|
|
||||||
|
await caches.names.invalidate();
|
||||||
|
|
||||||
|
return res.json('ok');
|
||||||
|
}));
|
||||||
|
|
||||||
|
export default router;
|
|
@ -39,4 +39,5 @@ export const caches = {
|
||||||
nouns: new CacheObject('main', 'nouns.js', 10),
|
nouns: new CacheObject('main', 'nouns.js', 10),
|
||||||
terms: new CacheObject('main', 'terms.js', 10),
|
terms: new CacheObject('main', 'terms.js', 10),
|
||||||
inclusive: new CacheObject('main', 'inclusive.js', 10),
|
inclusive: new CacheObject('main', 'inclusive.js', 10),
|
||||||
|
names: new CacheObject('main', 'names.js', 10),
|
||||||
}
|
}
|
||||||
|
|
|
@ -761,17 +761,22 @@ export class TermsEntry {
|
||||||
}
|
}
|
||||||
|
|
||||||
export class Name {
|
export class Name {
|
||||||
constructor(name, origin, meaning, usage, legally, pros, cons, notablePeople, count, links) {
|
constructor({id, name, origin, meaning, usage, legally, pros, cons, notablePeople, links, namedays, namedaysComment, approved, base_id = null, author = null}) {
|
||||||
|
this.id = id;
|
||||||
this.name = name;
|
this.name = name;
|
||||||
this.origin = origin;
|
this.origin = origin;
|
||||||
this.meaning = meaning;
|
this.meaning = meaning;
|
||||||
this.usage = usage;
|
this.usage = usage;
|
||||||
this.legally = legally;
|
this.legally = legally;
|
||||||
this.pros = pros;
|
this.pros = pros ? pros.split('|') : [];
|
||||||
this.cons = cons;
|
this.cons = cons ? cons.split('|') : [];
|
||||||
this.notablePeople = notablePeople;
|
this.notablePeople = notablePeople ? notablePeople.split('|') : [];
|
||||||
this.count = count; // TODO
|
this.links = links ? links.split('|') : [];
|
||||||
this.links = links.filter(l => l.trim().length);
|
this.namedays = namedays ? namedays.split('|') : [];
|
||||||
|
this.namedaysComment = namedaysComment;
|
||||||
|
this.approved = !!approved;
|
||||||
|
this.base = base_id;
|
||||||
|
this.author = author;
|
||||||
}
|
}
|
||||||
|
|
||||||
matches(filter) {
|
matches(filter) {
|
||||||
|
|
18
src/data.js
18
src/data.js
|
@ -49,24 +49,6 @@ export const pronounGroups = buildList(function* () {
|
||||||
|
|
||||||
export const pronounLibrary = new PronounLibrary(pronounGroups, pronouns);
|
export const pronounLibrary = new PronounLibrary(pronounGroups, pronouns);
|
||||||
|
|
||||||
import namesRaw from '../data/names/names.tsv';
|
|
||||||
export const names = buildDict(function* () {
|
|
||||||
for (let n of namesRaw) {
|
|
||||||
yield [n.name, new Name(
|
|
||||||
n.name,
|
|
||||||
n.origin,
|
|
||||||
n.meaning,
|
|
||||||
n.usage,
|
|
||||||
n.legally,
|
|
||||||
n.pros ? n.pros.split(',') : [],
|
|
||||||
n.cons ? n.cons.split(',') : [],
|
|
||||||
n.notablePeople ? n.notablePeople.split(',') : [],
|
|
||||||
n.count,
|
|
||||||
n.links ? n.links.split(' ') : [],
|
|
||||||
)];
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
import peopleRaw from '../data/people/people.tsv';
|
import peopleRaw from '../data/people/people.tsv';
|
||||||
export const people = buildList(function* () {
|
export const people = buildList(function* () {
|
||||||
for (let p of peopleRaw) {
|
for (let p of peopleRaw) {
|
||||||
|
|
Reference in New Issue