Giter Site home page Giter Site logo

react-layout-scale's Introduction

react-layout-scale

简介

布局缩放组件

安装

npm i @twp0217/react-layout-scale

使用

import LayoutScaleContainer from '@twp0217/react-layout-scale';

export default () => (
  <LayoutScaleContainer
    config={{
      width: 1920,
      height: 1080,
    }}
  >
    内容
  </LayoutScaleContainer>
);

API

LayoutScaleSize

名称 类型 默认值 说明
width number - 宽度
height number - 高度
scale number - 缩放值
configWidth number - 配置宽度
configHeight number - 配置高度

LayoutScaleContainerConfig

名称 类型 默认值 说明
width number - 宽度
height number - 高度

LayoutScaleContainerProps

名称 类型 默认值 说明
config LayoutScaleContainerConfig - 配置
containerClassName string - 容器类名
containerStyle string - 容器样式
contentClassName string - 内容类名
contentStyle string - 内容样式

支持

  • 如果项目对你有帮助,请点颗星:star:,谢谢。
  • 如果你对项目有想法、问题、BUG,欢迎讨论。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.