1.0.4 • Published 1 year ago

svelte-resize v1.0.4

Weekly downloads
-
License
-
Repository
-
Last release
1 year ago

Resize Svelte

Description

svelte-resize is vanilla without any 3rd party dependencies library made for svelte written in typescript. Super simple API thats easy to integrate.

Demo

Recording 2023-02-26 at 18 43 47

Installation

With pnpm:

pnpm install svelte-resize

With Yarn:

yarn add svelte-resize

With NPM:

npm install svelte-resize

Usage

<script>
  import { resize } from 'svelte-resize'
</script>


<div use:resize />

Props

Main props

propDescriptiontypedefaultrequired
disabledDisables resizebooleanfalsefalse
minimumSizeSets the minimum size in px the node is allowed to resizenumber20 pxfalse
maximumSizeSets the maxiumum size in px the node is allowed to resizenumbernullfalse
handlerSizeSize of the resize handlernumber10 pxfalse
handlersSpecifies the corner that is able to resize{ leftTop, leftBottom, rightTop, rightBottom }{ leftTop: true, leftBottom: true, rightTop: true, rightBottom: true }false
borderStyleStyle applied to handlerstring""2px solid rgba(0, 0, 0, 0.4)"false
1.0.4

1 year ago

1.0.4-rc

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago