feat: 更换用于前端显示的图片格式。

This commit is contained in:
2023-01-02 20:59:32 +08:00
parent 366b137258
commit 9030d48e21
8 changed files with 498 additions and 421 deletions

View File

@ -31,7 +31,7 @@ export const DisplayWithLedStrips: FC<DisplayWithLedStripsProps> = ({
...htmlAttrs
}) => {
const screenshotUrl = useMemo(
() => `data:image/png;base64,${screenshot.encode_image}`,
() => `data:image/ico;base64,${screenshot.encode_image}`,
[screenshot.encode_image],
);

View File

@ -1,7 +1,7 @@
import { HTMLAttributes, useMemo } from 'react';
import { FC } from 'react';
import { LedStripConfig } from '../models/led-strip-config';
import tw, { css, styled, theme } from 'twin.macro';
import tw, { css, styled } from 'twin.macro';
import { splitEvery } from 'ramda';
export interface LedStripProps extends HTMLAttributes<HTMLElement> {