mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-21 07:06:00 +00:00
show pages in iframe
This commit is contained in:
@@ -4,6 +4,11 @@ import _ from 'lodash';
|
||||
export function getIconImage(src, props) {
|
||||
const { size = 16, style = {}, className, title } = props || {};
|
||||
if (!src) return null;
|
||||
|
||||
if (src.startsWith('fas ') || src.startsWith('far ')) {
|
||||
return <i className={src} />;
|
||||
}
|
||||
|
||||
if (src.endsWith('.svg')) {
|
||||
// eslint-disable-next-line
|
||||
src = `${process.env.PUBLIC_URL}/icons/${src}`;
|
||||
|
||||
Reference in New Issue
Block a user