mirror of
https://github.com/mastermindzh/rickvanlieshout.com
synced 2024-12-25 06:18:58 +01:00
Merge pull request #319 from stigrune/master
Fixed invalid Telegram contact url
This commit is contained in:
commit
03cdea6852
@ -122,7 +122,7 @@ exports[`Contacts renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -108,7 +108,7 @@ exports[`Sidebar renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -111,7 +111,7 @@ exports[`CategoriesListTemplate renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -111,7 +111,7 @@ exports[`CategoryTemplate renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -111,7 +111,7 @@ exports[`IndexTemplate renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -111,7 +111,7 @@ exports[`NotFoundTemplate renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -111,7 +111,7 @@ exports[`PageTemplate renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -111,7 +111,7 @@ exports[`TagTemplate renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -111,7 +111,7 @@ exports[`TagsListTemplate renders correctly 1`] = `
|
||||
>
|
||||
<a
|
||||
className="contacts__list-item-link"
|
||||
href="telegram:#"
|
||||
href="https://t.me/#"
|
||||
rel="noopener noreferrer"
|
||||
target="_blank"
|
||||
>
|
||||
|
@ -13,7 +13,7 @@ const getContactHref = (name: string, contact: string) => {
|
||||
href = `https://vk.com/${contact}`;
|
||||
break;
|
||||
case 'telegram':
|
||||
href = `telegram:${contact}`;
|
||||
href = `https://t.me/${contact}`;
|
||||
break;
|
||||
case 'email':
|
||||
href = `mailto:${contact}`;
|
||||
|
@ -6,6 +6,6 @@ test('getContactHref', () => {
|
||||
expect(getContactHref('github', '#')).toBe('https://github.com/#');
|
||||
expect(getContactHref('email', '#')).toBe('mailto:#');
|
||||
expect(getContactHref('vkontakte', '#')).toBe('https://vk.com/#');
|
||||
expect(getContactHref('telegram', '#')).toBe('telegram:#');
|
||||
expect(getContactHref('telegram', '#')).toBe('https://t.me/#');
|
||||
expect(getContactHref('rss', '#')).toBe('#');
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user