Socket
Socket
Sign inDemoInstall

collapsible-split-layout

Package Overview
Dependencies
87
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    collapsible-split-layout

A React component to display a splitted layout were one of the sides can be collapsed/expanded without affecting the whole layout.


Version published
Maintainers
1
Created

Readme

Source

collapsible-split-layout Weekly downloads

A React component to display a splitted layout were one of the sides can be collapsed/expanded without affecting the whole layout.


Demo

You can access the storybook for these components here.

Props

There are three components. One (CollapsibleSplitLayout) for displaying on demand one of the following components and two components (CollapsibleSplitLayoutHorizontal and CollapsibleSplitLayoutVertical) used by the first component.

Props accepted by CollapsibleSplitLayout/CollapsibleSplitLayoutHorizontal/CollapsibleSplitLayoutVertical

NameTypeRequiredDefaultDescription
childCollapsibleReact.ReactNodeyes-The collapsible component
childViewReact.ReactNodeyes-The non-collapsible component
gapnumberno0The gap between componetns in MUI units (1 unit = 8px)
isReversedbooleannofalseThe collapsible component is for false on the left
maxCollapsibleSizenumberno-The max size of collapsible component
minCollapsibleSizenumberno-The min size of collapsible component

Only for CollapsibleSplitLayout

NameTypeRequiredDefaultDescription
isVerticalbooleannofalseIt is used the CollapsibleSplitLayoutHorizontal

Versions

CollapsibleSplitLayout usesReact
1.0.x18.0.0

About versioning schema used for CollapsibleSplitLayout

  • Major - it will be increased if the major version of the dependat package changes or there are breaking changes in the code of CollapsibleSplitLayout or CollapsibleSplitLayoutRaw
  • Minor - it will be increased if no major version of the dependat package changes, but there are changes of the minor or patch versions of it
  • Patch - it will be increased if there are no changes of the dependat packages, but there are non breaking changes in the code of CollapsibleSplitLayout or CollapsibleSplitLayoutRaw

Example

Displaying a horizontal layout (collapsible on left):

import * as React from 'react';
import { CollapsibleSplitLayoutHorizontal } from 'collapsible-split-layout';

class App extends React.Component {
  render() {
    return (
      <div className="App">
        <CollapsibleSplitLayoutHorizontal
          childCollapsible={<FlexibleBox />}
          childView={<FixView />}
        />
      </div>
    );
  }
}

export default App;

Displaying a reversed vertical layout (collapsible down):

import * as React from 'react';
import { CollapsibleSplitLayoutRaw } from 'collapsible-split-layout';

class App extends React.Component {
  render() {
    return (
      <div className="App">
        <CollapsibleSplitLayout
          isVertical
          childCollapsible={<FlexibleBox />}
          childView={<FixView />}
          isReversed
        />
      </div>
    );
  }
}

export default App;

Changelog

1.0.0

  • collapsible-split-layout is made publicly available

1.0.1

  • Fixed bundled lib

Keywords

FAQs

Last updated on 10 Dec 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc