Merge remote-tracking branch 'upstream/develop' into develop

This commit is contained in:
gianantoniopini
2020-12-09 10:35:39 +01:00
37 changed files with 1206 additions and 6049 deletions

View File

@ -60,16 +60,14 @@ const SidebarSection = ({ id, event }) => {
);
};
const LeftSidebar = () => {
return (
<div className="flex">
<LeftNavbar />
const LeftSidebar = () => (
<div className="flex">
<LeftNavbar />
<div id="LeftSidebar" className={styles.container}>
{sections.map(SidebarSection)}
</div>
<div id="LeftSidebar" className={styles.container}>
{sections.map(SidebarSection)}
</div>
);
};
</div>
);
export default memo(LeftSidebar);

View File

@ -4,25 +4,23 @@ import SectionIcon from '../../shared/SectionIcon';
import styles from './RightNavbar.module.css';
import SyncIndicator from './SyncIndicator';
const RightNavbar = () => {
return (
<div className={styles.container}>
<div className="grid grid-cols-1 gap-4 text-primary-500">
{sections.map((x) => (
<SectionIcon
key={x.id}
section={x}
containerId="RightSidebar"
tooltipPlacement="left"
/>
))}
</div>
<hr className="mt-auto my-6" />
<SyncIndicator />
const RightNavbar = () => (
<div className={styles.container}>
<div className="grid grid-cols-1 gap-4 text-primary-500">
{sections.map((x) => (
<SectionIcon
key={x.id}
section={x}
containerId="RightSidebar"
tooltipPlacement="left"
/>
))}
</div>
);
};
<hr className="mt-auto my-6" />
<SyncIndicator />
</div>
);
export default memo(RightNavbar);

View File

@ -45,16 +45,14 @@ const SidebarSection = ({ id, event }) => {
);
};
const RightSidebar = () => {
return (
<div className="flex">
<div id="RightSidebar" className={styles.container}>
{sections.map(SidebarSection)}
</div>
<RightNavbar />
const RightSidebar = () => (
<div className="flex">
<div id="RightSidebar" className={styles.container}>
{sections.map(SidebarSection)}
</div>
);
};
<RightNavbar />
</div>
);
export default memo(RightSidebar);

View File

@ -4,18 +4,16 @@ import Avatar from '../shared/Avatar';
import Logo from '../shared/Logo';
import styles from './TopNavbar.module.css';
const TopNavbar = () => {
return (
<div className={styles.navbar}>
<div className="container">
<Link to="/">
<Logo size="40px" />
</Link>
const TopNavbar = () => (
<div className={styles.navbar}>
<div className="container">
<Link to="/">
<Logo size="40px" />
</Link>
<Avatar className="ml-8" />
</div>
<Avatar className="ml-8" />
</div>
);
};
</div>
);
export default memo(TopNavbar);

View File

@ -3,19 +3,17 @@ import React, { memo } from 'react';
import { getRandomTip } from '../../data/tips';
import Logo from '../shared/Logo';
const LoadingScreen = () => {
return (
<Modal open hideBackdrop>
<Fade in>
<div className="w-screen h-screen flex justify-center items-center outline-none">
<div className="flex flex-col items-center">
<Logo size="48px" className="mb-4" />
<span className="font-medium opacity-75">{getRandomTip()}</span>
</div>
const LoadingScreen = () => (
<Modal open hideBackdrop>
<Fade in>
<div className="w-screen h-screen flex justify-center items-center outline-none">
<div className="flex flex-col items-center">
<Logo size="48px" className="mb-4" />
<span className="font-medium opacity-75">{getRandomTip()}</span>
</div>
</Fade>
</Modal>
);
};
</div>
</Fade>
</Modal>
);
export default memo(LoadingScreen);

View File

@ -8,13 +8,9 @@ const defaultState = { events: ModalEvents, emitter };
const ModalContext = createContext(defaultState);
const ModalProvider = ({ children }) => {
return (
<ModalContext.Provider value={defaultState}>
{children}
</ModalContext.Provider>
);
};
const ModalProvider = ({ children }) => (
<ModalContext.Provider value={defaultState}>{children}</ModalContext.Provider>
);
export default ModalContext;

View File

@ -83,6 +83,10 @@ const languages = [
code: 'tr',
name: 'Turkish (Türkçe)',
},
{
code: 'uk',
name: 'Ukrainian (Українська)',
},
];
i18n.use(initReactI18next).init({

View File

@ -96,7 +96,7 @@
"photograph": "صورة فوتوغرافية",
"firstName": "الاسم الاول",
"lastName": "اسم العائلة",
"birthDate": "تاريخ الولادة",
"birthDate": "تاريخ الميلاد",
"address": {
"line1": "العنوان الأول",
"line2": "العنوان الثاني",

View File

@ -17,6 +17,7 @@ import ptPt from './pt-pt.json';
import ru from './ru.json';
import sv from './sv.json';
import tr from './tr.json';
import uk from './uk.json';
import zh from './zh.json';
export default {
@ -39,5 +40,6 @@ export default {
ru: { translation: ru },
sv: { translation: sv },
tr: { translation: tr },
uk: { translation: uk },
zh: { translation: zh },
};

View File

@ -96,7 +96,7 @@
"photograph": "Fotografia",
"firstName": "Nome",
"lastName": "Cognome",
"birthDate": "Data di Nascita",
"birthDate": "Data di nascita",
"address": {
"line1": "Riga Indirizzo 1",
"line2": "Riga Indirizzo 2",

View File

@ -96,7 +96,7 @@
"photograph": "Fotografia",
"firstName": "Imię",
"lastName": "Nazwisko",
"birthDate": "Data urodzenia",
"birthDate": "Data urodzin",
"address": {
"line1": "Pole adresowe 1",
"line2": "Pole adresowe 2",

252
src/i18n/locales/uk.json Normal file
View File

@ -0,0 +1,252 @@
{
"shared": {
"appName": "Reactive Resume",
"shortDescription": "Безкоштовний, open source конструктор резюме.",
"forms": {
"name": "Назва",
"title": "Заголовок",
"subtitle": "Підзаголовок",
"required": "обов'язково",
"website": "Веб сайт",
"date": "Дата",
"present": "теперішній час",
"position": "Посада",
"startDate": "Дата початку",
"endDate": "Дата завершення",
"address": "Адреса",
"phone": "Номер телефону",
"email": "E-mail адреса",
"summary": "Резюме",
"markdown": "Цей текстовий блок підтримує <1> markdown </1>.",
"validation": {
"min": "Будь ласка, введіть мінімум {{number}} знаки.",
"dateRange": "Дата закінчення має бути пізніше, ніж дата початку.",
"email": "Адреса ел. пошти повинна бути дійсною.",
"required": "Це поле є обов`язковим.",
"url": "Повинен бути діючий URL."
}
},
"buttons": {
"add": "Додати",
"edit": "Змінити",
"cancel": "Скасувати",
"delete": "Видалити",
"loading": "Завантаження...",
"confirmation": "Ви впевнені?",
"login": "Вхід",
"logout": "Вихід"
}
},
"landing": {
"hero": {
"goToApp": "Перейти до додатка"
}
},
"dashboard": {
"title": "Панель управління",
"createResume": "Створити Резюме",
"editResume": "Редагувати Резюме",
"lastUpdated": "Останнє оновлення {{timestamp}}",
"toasts": {
"deleted": "{{name}} був успішно видалений"
},
"buttons": {
"duplicate": "Дублювати",
"rename": "Перейменувати"
},
"helpText": "Ви збираєтеся створити нове резюме з нуля, але спочатку давайте дамо йому ім'я. Це може бути назва посади, на яку ви хочете подати заявку, або, якщо ви складаєте резюме для друга, ви можете назвати його «Резюме Алекса»."
},
"builder": {
"toasts": {
"formErrors": "Можливо, вам буде потрібно заповнити всі обов'язкові поля перед відправкою цієї форми.",
"doesNotExist": "Резюме, яке ви шукали, більше не існує ... або, може бути, його ніколи не було?",
"loadDemoData": "Не впевнений, з чого почати? Спробуйте завантажити демо-дані, щоб дізнатися, що може запропонувати Reactive Resume.",
"printError": "У хмарної функції виникли проблеми, спробуйте ще раз пізніше або скористайтеся функцією друку браузера."
},
"sections": {
"heading": "Заголовок",
"profile": "Профіль",
"social": "Соціальна мережа",
"objective": "Завдання",
"work": "Досвід роботи",
"education": "Освіта",
"project": "Проект",
"projects": "Проекти",
"award": "Нагорода",
"awards": "Нагороди",
"certification": "Сертифікат",
"certifications": "Сертифікати",
"skill": "Навичка",
"skills": "Навички",
"hobby": "Хобі",
"hobbies": "Хобі",
"language": "Мова",
"languages": "Мови",
"reference": "Посилання",
"references": "Посилання",
"templates": "Шаблони",
"layout": "Розмітка",
"colors": "Кольори",
"fonts": "Шрифти",
"actions": "Дії",
"settings": "Налаштування",
"about": "Про програму"
},
"profile": {
"photograph": "Фотографія",
"firstName": "Ім'я",
"lastName": "Прізвище",
"birthDate": "Дата народження",
"address": {
"line1": "Адреса, рядок 1",
"line2": "Адреса, рядок 2",
"city": "Місто",
"pincode": "Індекс"
}
},
"social": {
"network": "Мережа",
"username": "Ім'я користувача",
"url": "URL"
},
"work": {
"company": "Організація"
},
"education": {
"institution": "Установа",
"field": "Область дослідження",
"degree": "Тип ступеня",
"gpa": "Середній бал"
},
"awards": {
"awarder": "Нагороджений"
},
"certifications": {
"issuer": "Ким виданий"
},
"skills": {
"level": "Рівень"
},
"languages": {
"fluency": "Вільне володіння"
},
"layout": {
"block": "Блокувати",
"reset": "Скинути макет",
"text": "Цей шаблон підтримує {{count}} блоків."
},
"colors": {
"primary": "Основний колір",
"text": "Колір тексту",
"background": "Колір фону"
},
"actions": {
"import": {
"heading": "Імпортувати Резюме",
"text": "Ви можете імпортувати свою інформацію з різних джерел, таких як JSON Resume або LinkedIn, щоб автоматично заповнювати більшу частину даних для свого резюме.",
"button": "Імпорт"
},
"export": {
"heading": "Експорт Вашого Резюме",
"text": "Експортуйте своє резюме в форматі PDF, щоб поділитися з рекрутерами, або в форматі JSON, який ви зможете імпортувати назад в цей додаток на іншому комп'ютері.",
"button": "Експорт"
},
"share": {
"heading": "Поділитися Вашим Резюме",
"text": "Посилання нижче буде доступна для всіх, якщо ви вирішите поділитися нею, і глядачі побачать останню версію вашого резюме в будь-який час."
},
"loadDemoData": {
"text": "Незрозуміло, що робити зі свіжої порожньою сторінкою? Завантажте демо-дані, щоб побачити, як має виглядати резюме, і можете починати редагування звідти.",
"button": "Завантажити демо-дані"
},
"resetEverything": {
"text": "Схоже, ви зробили дуже багато помилок? Не турбуйтеся, очистіть все одним клацанням миші, але будьте обережні, якщо немає резервних копій.",
"button": "Скинути все"
}
},
"settings": {
"theme": "Тема",
"language": "Мова",
"translate": "Якщо ви хочете внести свій внесок, надавши переклади на свою мову, <1> перейдіть за цим посиланням </ 1>.",
"dangerZone": {
"heading": "Небезпечна зона",
"text": "Якщо ви хочете видалити свій обліковий запис і стерти всі свої резюме, це всього лише одна кнопка. Будьте обережні, це незворотний процес.",
"button": "Видалити акаунт"
}
},
"about": {
"donate": {
"heading": "Пожертвувати на Reactive Resume",
"text": "Я намагаюся робити все, що в моїх силах, але якщо ви знайшли додаток корисним або ви перебуваєте в кращому становищі, ніж інші, які залежать від цього проекту в своїй першій роботі, <1> розгляньте можливість пожертвувати всього 5 доларів, щоб допомогти зберегти проект живим </ 1> :)",
"button": "Купіть мені кави!"
},
"bugFeature": {
"heading": "Помилка? Пропозиція?",
"text": "Щось заважає вам скласти резюме? Знайшли набридливу помилку, яка просто не зникне? Обговоріть це в розділі GitHub Issues, використовуючи такі дії.",
"button": "Підняти питання"
},
"appreciate": {
"heading": "Подобається Reactive Resume?",
"text": "Я ніколи не втомлююся чути історії про те, як цей додаток допоміг людям, і якщо він допоміг вам, або ви просто виявили, що Reactive Resume - відмінний інструмент, дайте мені знати. Ви можете зв'язатися зі мною на моєму веб-сайті."
},
"sourceCode": {
"heading": "Вихідний код",
"text": "Хочете запустити проект з вихідного коду? Ви розробник, який бажає внести свій вклад в розробку цього проекту з відкритим вихідним кодом? Натисніть кнопку нижче.",
"button": "GitHub репозиторій"
},
"footer": "Зроблено з любов'ю <1> Амрут Піллаі </ 1>"
},
"tooltips": {
"uploadPhotograph": "Завантажити фотографію",
"backToDashboard": "Повернутися до панелі управління"
},
"emptyList": "Цей список порожній."
},
"modals": {
"auth": {
"whoAreYou": "Хто ви?",
"welcome": "Ласкаво просимо, {{name}}!",
"loggedOutText": "Reactive Resume має знати, хто ви, щоб безпечно аутентифицировать вас в додатку і відображати тільки вашу інформацію. Як тільки ви ввійдете, ви можете почати створювати своє резюме, редагувати його, щоб додати нові навички або ділитися ним з усім світом!",
"loggedInText": "Приголомшливо. Тепер, коли ви пройшли аутентифікацію, ми можемо розібратися, чому ви тут. Натисніть кнопку «Перейти в додаток», щоб почати створювати своє резюме!",
"buttons": {
"google": "Ввійти за допомогою Google",
"anonymous": "Ввійти анонімно"
}
},
"import": {
"button": "Вибрати Файл",
"reactiveResume": {
"heading": "Імпорт з Reactive Resume",
"text": "Reactive Resume має свій власний формат схеми, щоб максимально використовувати всі можливості налаштувань, які воно може запропонувати. Якщо ви хочете імпортувати резервну копію свого резюме, зробленого за допомогою цього додатка, просто завантажте файл, використовуючи кнопку нижче."
},
"jsonResume": {
"heading": "Імпорт з резюме JSON",
"text": "JSON Resume - це відкритий стандарт структури схеми резюме. Якщо ви один з багатьох ентузіастів, у яких готове своє резюме в цьому форматі, досить одного клацання мишки, щоб почати роботу з Reactive Resume."
},
"linkedIn": {
"heading": "Імпорт з LinkedIn",
"text": "Ви можете імпортувати JSON, який був експортований з LinkedIn, натиснувши кнопку нижче і вибравши відповідний файл."
}
},
"export": {
"printDialog": {
"heading": "Використовуйте діалогове вікно друку браузера",
"text": "Тим з вас, хто хоче знайти швидке рішення, не потрібно шукати далі свого браузера. Все, що вам потрібно зробити, це натиснути Ctrl / Cmd + P, відкрити діалогове вікно друку в браузері і відразу ж роздрукувати своє резюме.",
"button": "Роздрукувати резюме"
},
"downloadPDF": {
"heading": "Завантажити PDF",
"text": "Ці параметри дозволяють вам надрукувати необмежену версію вашого резюме, що ідеально підходить для тих, у кого багато контенту. Крім того, ви можете завантажити багатосторінкову версію свого резюме одним кліком миші.",
"buttons": {
"single": "Односторінкове Резюме",
"multi": "Багатосторінкове Резюме"
}
},
"jsonFormat": {
"heading": "Експорт в формат JSON",
"text": "Ви також можете експортувати свої дані в формат JSON для безпечного зберігання, щоб ви могли легко імпортувати їх назад в Reactive Resume, коли захочете відредагувати або згенерувати резюме.",
"button": "Експорт JSON"
}
}
}
}

View File

@ -14,25 +14,23 @@ import SkillModal from './sections/SkillModal';
import SocialModal from './sections/SocialModal';
import WorkModal from './sections/WorkModal';
const ModalRegistrar = () => {
return (
<>
<AuthModal />
<ResumeModal />
<SocialModal />
<WorkModal />
<EducationModal />
<ProjectModal />
<AwardModal />
<CertificateModal />
<SkillModal />
<HobbyModal />
<LanguageModal />
<ReferenceModal />
<ImportModal />
<ExportModal />
</>
);
};
const ModalRegistrar = () => (
<>
<AuthModal />
<ResumeModal />
<SocialModal />
<WorkModal />
<EducationModal />
<ProjectModal />
<AwardModal />
<CertificateModal />
<SkillModal />
<HobbyModal />
<LanguageModal />
<ReferenceModal />
<ImportModal />
<ExportModal />
</>
);
export default memo(ModalRegistrar);

View File

@ -4,112 +4,110 @@ import { Helmet } from 'react-helmet';
import { MdKeyboardArrowLeft } from 'react-icons/md';
import Wrapper from '../components/shared/Wrapper';
const FrequentlyAskedQuestions = () => {
return (
<Wrapper>
<Helmet>
<title>Frequently Asked Questions | Reactive Resume</title>
<link rel="canonical" href="https://rxresu.me/app/dashboard" />
</Helmet>
const FrequentlyAskedQuestions = () => (
<Wrapper>
<Helmet>
<title>Frequently Asked Questions | Reactive Resume</title>
<link rel="canonical" href="https://rxresu.me/app/dashboard" />
</Helmet>
<div className="md:w-1/2 container px-8 md:px-0 py-16 grid gap-12">
<div className="flex items-center">
<Link to="/">
<MdKeyboardArrowLeft size="32px" />
</Link>
<h1 className="ml-6 text-4xl font-semibold">
Frequently Asked Questions
</h1>
</div>
<div>
<p className="leading-loose">
This is aimed to be the world&apos;s simplest privacy policy. This
document should explain to you why the app collects some
information, what happens when your account is deleted and some
other frequently asked questions answered regarding your privacy.
</p>
<p className="mt-6 leading-loose">
If you have any more questions, please raise an issue regarding the
same on GitHub and I&apos;ll answer as honest and quickly as
possible :)
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
What identifiable information is stored about me?
</h4>
<p className="leading-loose">
Your name and your email address is stored along with your user
information, if you signed in with Google, and of course, all the
information you input in your resume is also stored in the database.
You won&apos;t even get any marketing emails, feature updates,
newsletters, notification emails, nothing.
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
Why are you using a database, why not keep everything local like in
the first version of Reactive Resume?
</h4>
<p className="leading-loose">
Not having a centralized database cause a lot more problems than I
could solve, mainly having a large chunk of the users of the app
having an outdated schema as the app evolved. This was a problem I
could not solve without having at least some control.
</p>
<p className="mt-6 leading-loose">
Also, a lot of users were having trouble printing their resumes on
their browsers, so with the help of Cloud Functions from Firebase,
you can now print your resumes remotely. None of the resumes are
stored, and they are sent to you immediately after generation, which
can be verified by looking through the source code.
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
How is this all free? There must be a catch!
</h4>
<p className="leading-loose">
<strong>Absolutely no catch to this freebie.</strong> This project
is just my way of giving back to the community that I&apos;ve
learned so much from. If you&apos;d like to show your appreciation
however, you can follow me on my social media and let me know how
much it helped you, or donate to help pay the cloud bills, or if you
are a fellow developer, you can head to GitHub and contribute to the
code and raising a PR.
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
Is there a mobile app for Reactive Resume?
</h4>
<p className="leading-loose">
<strong>Not yet. But soon, maybe?</strong> One of the main
motivations for me to shift to a centralized database approach was
that I could one day build a mobile app as well that could let users
jump from editing on their desktops to editing on their phones. It
requires a lot of time, so I would not expect it any time soon, but
it&apos;s definitely in the pipeline.
</p>
</div>
<div className="md:w-1/2 container px-8 md:px-0 py-16 grid gap-12">
<div className="flex items-center">
<Link to="/">
<MdKeyboardArrowLeft size="32px" />
</Link>
<h1 className="ml-6 text-4xl font-semibold">
Frequently Asked Questions
</h1>
</div>
</Wrapper>
);
};
<div>
<p className="leading-loose">
This is aimed to be the world&apos;s simplest privacy policy. This
document should explain to you why the app collects some information,
what happens when your account is deleted and some other frequently
asked questions answered regarding your privacy.
</p>
<p className="mt-6 leading-loose">
If you have any more questions, please raise an issue regarding the
same on GitHub and I&apos;ll answer as honest and quickly as possible
:)
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
What identifiable information is stored about me?
</h4>
<p className="leading-loose">
Your name and your email address is stored along with your user
information, if you signed in with Google, and of course, all the
information you input in your resume is also stored in the database.
You won&apos;t even get any marketing emails, feature updates,
newsletters, notification emails, nothing.
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
Why are you using a database, why not keep everything local like in
the first version of Reactive Resume?
</h4>
<p className="leading-loose">
Not having a centralized database cause a lot more problems than I
could solve, mainly having a large chunk of the users of the app
having an outdated schema as the app evolved. This was a problem I
could not solve without having at least some control.
</p>
<p className="mt-6 leading-loose">
Also, a lot of users were having trouble printing their resumes on
their browsers, so with the help of Cloud Functions from Firebase, you
can now print your resumes remotely. None of the resumes are stored,
and they are sent to you immediately after generation, which can be
verified by looking through the source code.
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
How is this all free? There must be a catch!
</h4>
<p className="leading-loose">
<strong>Absolutely no catch to this freebie.</strong> This project is
just my way of giving back to the community that I&apos;ve learned so
much from. If you&apos;d like to show your appreciation however, you
can follow me on my social media and let me know how much it helped
you, or donate to help pay the cloud bills, or if you are a fellow
developer, you can head to GitHub and contribute to the code and
raising a PR.
</p>
</div>
<hr />
<div>
<h4 className="text-xl font-medium mb-4">
Is there a mobile app for Reactive Resume?
</h4>
<p className="leading-loose">
<strong>Not yet. But soon, maybe?</strong> One of the main motivations
for me to shift to a centralized database approach was that I could
one day build a mobile app as well that could let users jump from
editing on their desktops to editing on their phones. It requires a
lot of time, so I would not expect it any time soon, but it&apos;s
definitely in the pipeline.
</p>
</div>
</div>
</Wrapper>
);
export default FrequentlyAskedQuestions;

View File

@ -127,16 +127,14 @@ const Home = () => {
);
};
const Feature = ({ icon: Icon, title, children }) => {
return (
<div className="mt-16">
<div className="flex items-center">
<Icon size="18px" className="text-primary-900 mr-4" />
<div className="text-3xl">{title}</div>
</div>
<p className="mt-6 text-lg leading-loose">{children}</p>
const Feature = ({ icon: Icon, title, children }) => (
<div className="mt-16">
<div className="flex items-center">
<Icon size="18px" className="text-primary-900 mr-4" />
<div className="text-3xl">{title}</div>
</div>
);
};
<p className="mt-6 text-lg leading-loose">{children}</p>
</div>
);
export default memo(Home);

View File

@ -52,7 +52,6 @@ const ResumeViewer = ({ id }) => {
</Helmet>
<div
id="page"
className={styles.page}
style={{ backgroundColor: resume.metadata.colors.background }}
>

View File

@ -76,6 +76,7 @@ section {
#page {
width: 21cm;
position: absolute;
text-align: start;
top: 0;
left: 0;
right: 0;

View File

@ -55,6 +55,7 @@ const Castform = ({ data }) => {
return (
<PageContext.Provider value={{ data, heading: HeadingD }}>
<div
id="page"
className="rounded"
style={{
fontFamily: data.metadata.font,

View File

@ -86,6 +86,7 @@ const Celebi = ({ data }) => {
return (
<PageContext.Provider value={{ data, heading: HeadingE }}>
<div
id="page"
className="relative rounded"
style={{
fontFamily: data.metadata.font,

View File

@ -59,6 +59,7 @@ const Gengar = ({ data }) => {
return (
<PageContext.Provider value={{ data, heading: HeadingC }}>
<div
id="page"
className="rounded"
style={{
fontFamily: data.metadata.font,

View File

@ -54,6 +54,7 @@ const Glalie = ({ data }) => {
return (
<PageContext.Provider value={{ data, heading: HeadingB }}>
<div
id="page"
className="rounded"
style={{
fontFamily: data.metadata.font,

View File

@ -33,6 +33,7 @@ const Onyx = ({ data }) => {
return (
<PageContext.Provider value={{ data, heading: HeadingA }}>
<div
id="page"
className="p-8 rounded"
style={{
fontFamily: data.metadata.font,

View File

@ -32,6 +32,7 @@ const Pikachu = ({ data }) => {
return (
<PageContext.Provider value={{ data, heading: HeadingB }}>
<div
id="page"
className="p-8 rounded"
style={{
fontFamily: data.metadata.font,

View File

@ -3,8 +3,8 @@ import { useTranslation } from 'react-i18next';
import PageContext from '../../../contexts/PageContext';
import { safetyCheck } from '../../../utils';
const ContactItem = ({ value, label, link }) => {
return value ? (
const ContactItem = ({ value, label, link }) =>
value ? (
<div className="flex flex-col">
<h6 className="capitalize font-semibold">{label}</h6>
{link ? (
@ -16,7 +16,6 @@ const ContactItem = ({ value, label, link }) => {
)}
</div>
) : null;
};
const ContactC = () => {
const { t } = useTranslation();

View File

@ -4,8 +4,8 @@ import { MdFlare } from 'react-icons/md';
import PageContext from '../../../contexts/PageContext';
import { safetyCheck } from '../../../utils';
const ContactItem = ({ value, label, link }) => {
return value ? (
const ContactItem = ({ value, label, link }) =>
value ? (
<div className="flex flex-col">
<h6 className="capitalize font-semibold">{label}</h6>
{link ? (
@ -17,7 +17,6 @@ const ContactItem = ({ value, label, link }) => {
)}
</div>
) : null;
};
const ContactD = () => {
const { t } = useTranslation();

View File

@ -1,11 +1,7 @@
import React, { memo } from 'react';
const HeadingC = ({ children }) => {
return (
<h6 className="font-bold text-xs uppercase tracking-wide mb-1">
{children}
</h6>
);
};
const HeadingC = ({ children }) => (
<h6 className="font-bold text-xs uppercase tracking-wide mb-1">{children}</h6>
);
export default memo(HeadingC);

View File

@ -1,11 +1,9 @@
import React, { memo } from 'react';
const HeadingC = ({ children }) => {
return (
<h6 className="my-2 text-md uppercase font-semibold tracking-wider pb-1 border-b-2 border-gray-800">
{children}
</h6>
);
};
const HeadingC = ({ children }) => (
<h6 className="my-2 text-md uppercase font-semibold tracking-wider pb-1 border-b-2 border-gray-800">
{children}
</h6>
);
export default memo(HeadingC);

View File

@ -15,6 +15,7 @@ import 'dayjs/locale/nl';
import 'dayjs/locale/pl';
import 'dayjs/locale/pt';
import 'dayjs/locale/tr';
import 'dayjs/locale/uk';
import relativeTime from 'dayjs/plugin/relativeTime';
dayjs.extend(relativeTime);

View File

@ -1,15 +1,13 @@
import dayjs from 'dayjs';
import { get, isEmpty } from 'lodash';
export const getModalText = (isEditMode, type, t) => {
return isEditMode
export const getModalText = (isEditMode, type, t) =>
isEditMode
? `${t('shared.buttons.edit')} ${type}`
: `${t('shared.buttons.add')} ${type}`;
};
export const safetyCheck = (section, path = 'items') => {
return !!(section && section.visible === true && !isEmpty(section[path]));
};
export const safetyCheck = (section, path = 'items') =>
!!(section && section.visible === true && !isEmpty(section[path]));
export const handleKeyUp = (event, action) => {
(event.which === 13 || event.which === 32) && action();