mirror of
https://github.com/luxfi/explore.git
synced 2026-09-24 00:28:18 +00:00
add sprite build step to Docker file; remove unused Icon component; fix svgo config
This commit is contained in:
@@ -58,6 +58,7 @@ RUN ./collect_envs.sh ./docs/ENVS.md
|
|||||||
|
|
||||||
# Build app for production
|
# Build app for production
|
||||||
RUN yarn build
|
RUN yarn build
|
||||||
|
RUN yarn svg:build-sprite
|
||||||
|
|
||||||
|
|
||||||
### FEATURE REPORTER
|
### FEATURE REPORTER
|
||||||
|
|||||||
+9
-12
@@ -1,17 +1,14 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
plugins: [
|
plugins: [
|
||||||
// TODO @tom2drum pick up plugins from default preset
|
{
|
||||||
// {
|
name: 'preset-default',
|
||||||
// name: 'preset-default',
|
params: {
|
||||||
// params: {
|
overrides: {
|
||||||
// overrides: {
|
removeViewBox: false,
|
||||||
// removeViewBox: false,
|
removeHiddenElems: false,
|
||||||
// cleanupIds: false,
|
},
|
||||||
// removeUselessDefs: false,
|
},
|
||||||
// collapseGroups: false,
|
},
|
||||||
// },
|
|
||||||
// },
|
|
||||||
// },
|
|
||||||
'removeDimensions',
|
'removeDimensions',
|
||||||
],
|
],
|
||||||
js2svg: {
|
js2svg: {
|
||||||
|
|||||||
@@ -1,18 +0,0 @@
|
|||||||
import { Skeleton, Icon as ChakraIcon } from '@chakra-ui/react';
|
|
||||||
import type { IconProps, As } from '@chakra-ui/react';
|
|
||||||
import React from 'react';
|
|
||||||
|
|
||||||
interface Props extends IconProps {
|
|
||||||
isLoading?: boolean;
|
|
||||||
as: As;
|
|
||||||
}
|
|
||||||
|
|
||||||
const Icon = ({ isLoading, ...props }: Props, ref: React.LegacyRef<SVGSVGElement>) => {
|
|
||||||
return (
|
|
||||||
<Skeleton isLoaded={ !isLoading } boxSize={ props.boxSize } w={ props.w } h={ props.h } borderRadius={ props.borderRadius }>
|
|
||||||
<ChakraIcon { ...props } ref={ ref }/>
|
|
||||||
</Skeleton>
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
export default React.memo(React.forwardRef(Icon));
|
|
||||||
Reference in New Issue
Block a user