Fix whitespace and comment discrepancies

This commit is contained in:
Claire
2023-11-15 12:40:52 +01:00
parent 08ac91c40b
commit b1f0457cb8
5 changed files with 9 additions and 6 deletions

View File

@@ -1,3 +1,4 @@
// NB: This function can still return unsafe HTML
export const unescapeHTML = (html) => {
const wrapper = document.createElement('div');
wrapper.innerHTML = html.replace(/<br\s*\/?>/g, '\n').replace(/<\/p><p>/g, '\n\n').replace(/<[^>]*>/g, '');

View File

@@ -1,3 +1,5 @@
// Copied from emoji-mart for consistency with emoji picker and since
// they don't export the icons in the package
export const loupeIcon = (
<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' width='13' height='13'>
<path d='M12.9 14.32a8 8 0 1 1 1.41-1.41l5.35 5.33-1.42 1.42-5.33-5.34zM8 14A6 6 0 1 0 8 2a6 6 0 0 0 0 12z' />

View File

@@ -3,7 +3,7 @@
const checkNotificationPromise = () => {
try {
// eslint-disable-next-line promise/catch-or-return, promise/valid-params
// eslint-disable-next-line promise/valid-params, promise/catch-or-return
Notification.requestPermission().then();
} catch(e) {
return false;