-
+
+
+ 0
+ ? 'danger'
+ : 'none'
+ }
+ >
+ {widthInPixel} px
+ x
+ {heightInPixel} px
+ state.values.dpi}>
+ {(dpi) => @ {dpi}DPI}
+
+
+
+
+ {mode === 'basic' && (
+ <>
+
+ {(field) => (
+
+ )}
+
+
+ {(field) => (
+
+ )}
+
+ >
+ )}
+
+ {mode === 'advance' && (
+ <>
+ {
+ const newHeight = changeSize(
+ value,
+ 'height',
+ 'width',
+ );
+ form.setFieldValue('height', newHeight);
+ },
+ }}
+ >
+ {(field) => (
+ {unit}}
+ required
+ placeholder="width"
+ />
+ )}
+
+
+
+
+
+ {
+ const newWidth = changeSize(value, 'width', 'height');
+ form.setFieldValue('width', newWidth);
+ },
+ }}
+ >
+ {(field) => (
+ {unit}}
+ required
+ placeholder="height"
+ />
+ )}
+
+
+ {
+ const { width, height } = changeUnit({ unit: value });
+
+ form.setFieldValue('width', width);
+ form.setFieldValue('height', height);
+ },
+ }}
+ >
+ {(field) => (
+ ({
+ label: name,
+ value: unit,
+ }))}
+ />
+ )}
+
+ >
+ )}
+
+ {
+ if (unit === 'px') {
+ const convertedValue = changeDPI(value);
+
+ form.setFieldValue('width', convertedValue.width);
+ form.setFieldValue('height', convertedValue.height);
+ }
+ },
+ }}
+ >
+ {(field) => (
+
+ )}
+
+
+
+
+
+
+
+ {(field) => (
+
+ )}
+
-
{
- void handleSubmit(onExportOptionsChange)();
- }}
- doneLabel={confirmButtonText}
- onCancel={() => onCloseDialog?.()}
- />
-
-
+
+
+
Save
+
+
+