Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(locale): add Serbian (Latin) language #1801

Merged
merged 21 commits into from
Mar 20, 2023
Merged
Show file tree
Hide file tree
Changes from 20 commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/guide/localization.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ export const customFaker = new Faker({
| `ro` | Romanian | `fakerRO` |
| `ru` | Russian | `fakerRU` |
| `sk` | Slovakian | `fakerSK` |
| `sr_RS_latin` | Serbian (Latin) | `fakerSR_RS_latin` |
| `sv` | Swedish | `fakerSV` |
| `tr` | Turkish | `fakerTR` |
| `uk` | Ukrainian | `fakerUK` |
Expand Down
3 changes: 3 additions & 0 deletions src/locale/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ import { faker as fakerPT_PT } from './pt_PT';
import { faker as fakerRO } from './ro';
import { faker as fakerRU } from './ru';
import { faker as fakerSK } from './sk';
import { faker as fakerSR_RS_latin } from './sr_RS_latin';
import { faker as fakerSV } from './sv';
import { faker as fakerTR } from './tr';
import { faker as fakerUK } from './uk';
Expand Down Expand Up @@ -115,6 +116,7 @@ export {
fakerRO,
fakerRU,
fakerSK,
fakerSR_RS_latin,
fakerSV,
fakerTR,
fakerUK,
Expand Down Expand Up @@ -177,6 +179,7 @@ export const allFakers = {
ro: fakerRO,
ru: fakerRU,
sk: fakerSK,
sr_RS_latin: fakerSR_RS_latin,
sv: fakerSV,
tr: fakerTR,
uk: fakerUK,
Expand Down
12 changes: 12 additions & 0 deletions src/locale/sr_RS_latin.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*
* This file is automatically generated.
* Run 'pnpm run generate:locales' to update.
*/

import { Faker } from '../faker';
import en from '../locales/en';
import sr_RS_latin from '../locales/sr_RS_latin';

export const faker = new Faker({
locale: [sr_RS_latin, en],
});
1 change: 1 addition & 0 deletions src/locales/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ export { default as pt_PT } from './pt_PT';
export { default as ro } from './ro';
export { default as ru } from './ru';
export { default as sk } from './sk';
export { default as sr_RS_latin } from './sr_RS_latin';
export { default as sv } from './sv';
export { default as tr } from './tr';
export { default as uk } from './uk';
Expand Down
1 change: 1 addition & 0 deletions src/locales/sr_RS_latin/cell_phone/formats.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['06# ### ## ##', '06########', '+381 6# ### ####'];
11 changes: 11 additions & 0 deletions src/locales/sr_RS_latin/cell_phone/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/*
* This file is automatically generated.
* Run 'pnpm run generate:locales' to update.
*/
import formats from './formats';

const cell_phone = {
formats,
};

export default cell_phone;
14 changes: 14 additions & 0 deletions src/locales/sr_RS_latin/date/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/*
* This file is automatically generated.
* Run 'pnpm run generate:locales' to update.
*/
import type { DateDefinitions } from '../../..';
import month from './month';
import weekday from './weekday';

const date: DateDefinitions = {
month,
weekday,
};

export default date;
30 changes: 30 additions & 0 deletions src/locales/sr_RS_latin/date/month.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
export default {
wide: [
'januar',
'februar',
'mart',
'april',
'maj',
'jun',
'jul',
'avgust',
'septembar',
'oktobar',
'novembar',
'decembar',
],
abbr: [
'jan',
'feb',
'mar',
'apr',
'maj',
'jun',
'jul',
'avg',
'sep',
'okt',
'nov',
'dec',
],
};
12 changes: 12 additions & 0 deletions src/locales/sr_RS_latin/date/weekday.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
export default {
wide: [
'nedelja',
'ponedeljak',
'utorak',
'sreda',
'četvrtak',
'petak',
'subota',
],
abbr: ['ned', 'pon', 'uto', 'sre', 'čet', 'pet', 'sub'],
};
23 changes: 23 additions & 0 deletions src/locales/sr_RS_latin/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
/*
* This file is automatically generated.
* Run 'pnpm run generate:locales' to update.
*/
import type { LocaleDefinition } from '../..';
import cell_phone from './cell_phone';
import date from './date';
import internet from './internet';
import location from './location';
import person from './person';
import phone_number from './phone_number';

const sr_RS_latin: LocaleDefinition = {
title: 'Serbian (Latin)',
cell_phone,
date,
internet,
location,
person,
phone_number,
};

export default sr_RS_latin;
1 change: 1 addition & 0 deletions src/locales/sr_RS_latin/internet/domain_suffix.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['rs', 'com', 'co.rs', 'edu.rs', 'in.rs'];
12 changes: 12 additions & 0 deletions src/locales/sr_RS_latin/internet/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*
* This file is automatically generated.
* Run 'pnpm run generate:locales' to update.
*/
import type { InternetDefinitions } from '../../..';
import domain_suffix from './domain_suffix';

const internet: InternetDefinitions = {
domain_suffix,
};

export default internet;
1 change: 1 addition & 0 deletions src/locales/sr_RS_latin/location/building_number.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['#', '##', '###'];
1 change: 1 addition & 0 deletions src/locales/sr_RS_latin/location/city.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['{{location.city_name}}'];
29 changes: 29 additions & 0 deletions src/locales/sr_RS_latin/location/city_name.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
export default [
'Beograd',
'Bor',
'Jagodina',
'Kikinda',
'Kraljevo',
'Kruševac',
'Leskovac',
'Niš',
'Novi Pazar',
'Novi Sad',
'Pančevo',
'Paraćin',
'Pirot',
'Požarevac',
'Prokuplje',
'Smederevo',
'Sombor',
'Sopot',
'Sremska Mitrovica',
'Subotica',
'Užice',
'Vranje',
'Vršac',
'Zaječar',
'Zrenjanjin',
'Čačak',
'Šabac',
];
Loading