diff --git a/src/components/parser-components/external-link/external-link.js b/src/components/parser-components/external-link/external-link.js
index 831aea5..a73203f 100644
--- a/src/components/parser-components/external-link/external-link.js
+++ b/src/components/parser-components/external-link/external-link.js
@@ -2,24 +2,20 @@ import React from 'react';
import PropTypes from 'prop-types';
import { IconExternalLink } from '@tabler/icons-react';
-import Tooltip from '@/components/core/tooltip';
-
const linkClassName =
- 'inline-flex items-center gap-1 px-2 py-1 rounded text-primary underline hover:text-blue-900 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary';
+ 'inline-flex items-center text-primary underline rounded-sm hover:text-blue-900 focus-visible:outline focus-visible:outline-2 focus-visible:outline-primary';
-const ExternalLink = ({ display = '', target = '', title = '', newTab = false }) => {
- const anchor = (
-
- {display}
- {newTab && }
-
- );
- return title ? {anchor} : anchor;
-};
+const ExternalLink = ({ display = '', target = '', title = '', newTab = false }) => (
+
+ {display}
+ {newTab && }
+
+);
ExternalLink.propTypes = {
display: PropTypes.string,
diff --git a/src/components/parser-components/image/image.js b/src/components/parser-components/image/image.js
index ef896c4..6d1c36e 100644
--- a/src/components/parser-components/image/image.js
+++ b/src/components/parser-components/image/image.js
@@ -2,8 +2,6 @@ import React, { useState } from 'react';
import PropTypes from 'prop-types';
import { IconExternalLink } from '@tabler/icons-react';
-import Tooltip from '@/components/core/tooltip';
-
const useImageBroken = (source) => {
const [erroredSource, setErroredSource] = useState(null);
return {
@@ -44,23 +42,6 @@ LinkedImg.propTypes = {
onError: PropTypes.func,
};
-const AltTooltip = ({ alt = '', disabled = false, children }) => {
- if (!alt || disabled) return children;
- return (
-
-
- {children}
-
-
- );
-};
-
-AltTooltip.propTypes = {
- alt: PropTypes.string,
- disabled: PropTypes.bool,
- children: PropTypes.node.isRequired,
-};
-
const Caption = ({ display = '', children }) => (
{children}
@@ -74,12 +55,8 @@ Caption.propTypes = {
};
const Image = ({ alt = '', source = '' }) => {
- const { broken, onError } = useImageBroken(source);
- return (
-
-
-
- );
+ const { onError } = useImageBroken(source);
+ return
;
};
Image.propTypes = {
@@ -89,11 +66,7 @@ Image.propTypes = {
export const ImageLink = ({ alt = '', source = '', target = '' }) => {
const { broken, onError } = useImageBroken(source);
- return (
-
-
-
- );
+ return ;
};
ImageLink.propTypes = {
@@ -103,12 +76,10 @@ ImageLink.propTypes = {
};
export const ImageDisplay = ({ alt = '', display = '', source = '' }) => {
- const { broken, onError } = useImageBroken(source);
+ const { onError } = useImageBroken(source);
return (
-
-
-
+
);
};
@@ -123,9 +94,7 @@ export const ImageDisplayLink = ({ alt = '', display = '', source = '', target =
const { broken, onError } = useImageBroken(source);
return (
-
-
-
+
);
};
diff --git a/src/index.css b/src/index.css
index e0696e7..e862366 100644
--- a/src/index.css
+++ b/src/index.css
@@ -62,6 +62,13 @@ math {
padding-left: 1.5em;
}
+.right-side-preview-area table {
+ display: block;
+ width: max-content;
+ max-width: 100%;
+ overflow-x: auto;
+}
+
.right-side-preview-area table td,
.right-side-preview-area table th {
padding: 8px;
@@ -99,5 +106,5 @@ math {
}
.right-side-preview-area a:not([class]) {
- @apply inline-flex items-center gap-1 px-2 py-1 rounded text-primary underline hover:text-blue-900 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary;
+ @apply inline-flex items-center text-primary underline rounded-sm hover:text-blue-900 focus-visible:outline focus-visible:outline-2 focus-visible:outline-primary;
}