Skip to content

Commit 33a7223

Browse files
committed
chore: update preview
1 parent 239dcc8 commit 33a7223

File tree

7 files changed

+35
-14
lines changed

7 files changed

+35
-14
lines changed

packages/pluggableWidgets/barcode-generator-web/src/BarcodeGenerator.editorPreview.tsx

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
import { ReactElement } from "react";
2-
import "./ui/BarcodeGeneratorPreview.css";
3-
import BarcodePreview from "./assets/BarcodeGeneratorPreview.svg";
4-
import { BarcodeGeneratorPreviewProps } from "typings/BarcodeGeneratorProps";
5-
import classNames from "classnames";
2+
import { BarcodeGeneratorPreviewProps } from "../typings/BarcodeGeneratorProps";
3+
import BarcodePreviewSVG from "./assets/BarcodeGeneratorPreview.svg";
64

7-
export function preview(props: BarcodeGeneratorPreviewProps): ReactElement {
8-
let doc = decodeURI(BarcodePreview);
5+
export function preview(_props: BarcodeGeneratorPreviewProps): ReactElement {
6+
const doc = decodeURI(BarcodePreviewSVG);
97

108
return (
11-
<div className={classNames("barcode-generator-preview", props.class)}>
9+
<div className="barcode-generator-widget-preview">
1210
<img src={doc} alt="" />
1311
</div>
1412
);
636 Bytes
Loading
642 Bytes
Loading
2 KB
Loading
2.01 KB
Loading

packages/pluggableWidgets/barcode-generator-web/src/BarcodeGenerator.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import { createElement, ReactElement, useEffect, useRef } from "react";
2-
import { BarcodeGeneratorContainerProps } from "../typings/BarcodeGeneratorProps";
3-
import { QRCodeSVG } from "qrcode.react";
41
import JsBarcode from "jsbarcode";
2+
import { QRCodeSVG } from "qrcode.react";
3+
import { ReactElement, useEffect, useRef } from "react";
4+
import { BarcodeGeneratorContainerProps } from "../typings/BarcodeGeneratorProps";
55

66
import "./ui/BarcodeGenerator.scss";
77

Lines changed: 27 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,30 @@
11
{
2-
"extends": "@mendix/pluggable-widgets-tools/configs/tsconfig.base",
2+
"include": ["./src", "./typings"],
33
"compilerOptions": {
4-
"baseUrl": "./"
5-
},
6-
"include": ["./src", "./typings"]
4+
"baseUrl": "./",
5+
"noEmitOnError": true,
6+
"sourceMap": true,
7+
"module": "esnext",
8+
"target": "es6",
9+
"lib": ["esnext", "dom"],
10+
"types": ["jest", "node"],
11+
"moduleResolution": "node",
12+
"declaration": false,
13+
"noLib": false,
14+
"forceConsistentCasingInFileNames": true,
15+
"noFallthroughCasesInSwitch": true,
16+
"strict": true,
17+
"strictFunctionTypes": false,
18+
"skipLibCheck": true,
19+
"noUnusedLocals": true,
20+
"noUnusedParameters": true,
21+
"jsx": "react-jsx",
22+
"allowSyntheticDefaultImports": true,
23+
"esModuleInterop": true,
24+
"useUnknownInCatchVariables": false,
25+
"exactOptionalPropertyTypes": false,
26+
"paths": {
27+
"react-hot-loader/root": ["./hot-typescript.ts"]
28+
}
29+
}
730
}

0 commit comments

Comments
 (0)