Giter Site home page Giter Site logo

co-carroulsels's Introduction

Co-Carrousels

Co-Carrousels is a simple tool for make image Carousels on React.js. We are start. This is a original project of Samuel :)

Examples

We have two Carousels types for you.

Carousel for Full page

This carousel is designed so that you can use it completely on your screen. With full screen we mean that it uses the width: 100% and the height: 100vh; You can add more content below according to your needs.

This is a Fullpage Carousel


Small Carousel

This carousel is designed to be placed anywhere in React, you can fill spaces with small carousels to diversify the content a bit more, it's a nice minimalist design.

You can place the number of carousels you want without affecting performance and also that each carousel works independently.

This is a Normal Carousel


Instalation

To start using the library, we must install the package with our npm command make sure you have formatted your styles so you don't have any conflicts with the styles of the carousels

$ npm install co-carrousels

Once the module is installed it is time to start using the carousels

The module provides you 3 functions to import FullCarrousel, SmallCarrousel and CoImage

The Full Carrousel, Small Carrousel modules are the container components of the images that will contain

use this module if you want to use screen carousel

import { FullCarrousel, CoImage } from "co-carrousels";

export default function MyComponent() {
    return (
        <>
            <FullCarrousel controls="true">
                <CoImage src="imagePath" alt="" />
                <CoImage src="imagePath" alt="" />
                <CoImage src="imagePath" alt="" />

                {/*More images*/}
            </FullCarrousel>
        </>
    )
}

the controls attribute receives true and false, with this attribute you can decide whether or not to show the buttons to change the images


Use this module if you want to use the small carousel that you can use anywhere in your application

import { SmallCarrousel, CoImage } from "co-carrousels";

export default function MyComponent() {
    return (
        <>
            <SmallCarrousel borderRadius="12px" controls="true">
                <CoImage src="imagePath" alt="" />
                <CoImage src="imagePath" alt="" />
                <CoImage src="imagePath" alt="" />

                {/*More images*/}
            </SmallCarrousel>
        </>
    )
}

the borderRadius attribute allows you to put a rounded border to your carousel, you just have to put the amount in pixels as if it were CSS

co-carroulsels's People

Stargazers

S4muB0t avatar S4muB0t avatar

Watchers

S4muB0t avatar

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.