Skip to content

Commit cbf8d64

Browse files
committed
tweak: update opacity field to use slider input and fix min-size label formatting
1 parent bfafebf commit cbf8d64

File tree

1 file changed

+7
-2
lines changed
  • packages/imagekit-editor-dev/src/schema

1 file changed

+7
-2
lines changed

packages/imagekit-editor-dev/src/schema/index.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -627,7 +627,7 @@ export const transformationSchema: TransformationSchema[] = [
627627
},
628628
{
629629
key: "resize-at_least",
630-
name: "Min-size",
630+
name: "Min Size",
631631
// The min-size crop strategy resizes the image so that at least one
632632
// dimension is equal to or greater than the requested dimension. The
633633
// aspect ratio is preserved and the other dimension may exceed the
@@ -1343,11 +1343,16 @@ export const transformationSchema: TransformationSchema[] = [
13431343
{
13441344
label: "Opacity",
13451345
name: "opacity",
1346-
fieldType: "input",
1346+
fieldType: "slider",
13471347
isTransformation: true,
13481348
transformationKey: "opacity",
13491349
helpText: "Enter an opacity percentage between 0 and 100.",
13501350
examples: ["50"],
1351+
fieldProps: {
1352+
min: 0,
1353+
max: 100,
1354+
step: 1,
1355+
},
13511356
},
13521357
],
13531358
},

0 commit comments

Comments
 (0)