Code Monkey home page Code Monkey logo

yii2-daslider's Introduction

Delayed Animation Slider

Delayed Animation Slider is a simple content slider for the Yii 2 framework with animations for each slider element and the background parallax effect.

Screenshot

Real Demo

Installation

You can install the widget using Composer. Just run the following command under your application folder:

php composer.phar require --prefer-dist mickgeek/yii2-daslider

Usage

use yii\helpers\Html;
use mickgeek\daslider\Widget as DaSlider;

<?php DaSlider::begin([
    'clientOptions' => ['bgincrement' => 10, 'interval' => 3000],
]); ?>
    <div class="da-slide">
        <h2>Opera</h2>
        <p>Opera is a web browser developed by Opera Software. The latest version currently runs on Microsoft Windows and OS X operating systems and uses the Blink layout engine.</p>
        <?= Html::a('Read more', '#', ['class' => 'da-link btn btn-default btn-lg']) ?>

        <div class="da-img">
            <?= Html::img('/img/1.png', ['alt' => 'Opera']) ?>
        </div>
    </div>
    <div class="da-slide">
        <h2>CloneDVD</h2>
        <p>CloneDVD is a proprietary DVD cloning software, developed by Elaborate Bytes, that can be used to make backup copies of any DVD movie not copy-protected.</p>
        <?= Html::a('Read more', '#', ['class' => 'da-link btn btn-default btn-lg']) ?>

        <div class="da-img">
            <?= Html::img('/img/2.png', ['alt' => 'CloneDVD']) ?>
        </div>
    </div>
<?php DaSlider::end(); ?>

Widget Properties

  • registerModernizr: boolean, whether the Modernizr JavaScript library should be registered.

  • options: array, the HTML attributes for the widget container tag. See renderTagAttributes() for details on how attributes are being rendered.

  • clientOptions: array, options for the widget. The possible options:

    • current: integer, a number of the current slide.
    • bgincrement: integer, an increment of the background position when sliding (the parallax effect).
    • autoplay: boolean, whether to display the slideshow.
    • interval: integer, a duration between the transitions.

License

This extension is released under the BSD 3-Clause License. See the bundled LICENSE.md for details.

yii2-daslider's People

Contributors

mickgeek avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Forkers

heartshare

yii2-daslider's Issues

Invalid Configuration - The configuration for the "mickgeek/yii2-daslider" component must contain a "class" element.

According to the configuration file it says
'mickgeek/yii2-daslider' => [ 'name' => 'mickgeek/yii2-daslider', 'version' => '9999999-dev', 'alias' => [ '@mickgeek/daslider' => $vendorDir . '/mickgeek/yii2-daslider', ], ],
but that throws an error saying
The configuration for the "mickgeek/yii2-daslider" component must contain a "class" element.

It works when you actually change 'name' => 'mickgeek/yii2-daslider', to 'class' => 'mickgeek/yii2-daslider',
Please update the readme

Background Image?

Hi,

Is there a way i can change the background image?
Or is there a way to have different background images?

Thx in advance!

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.