예제 #1
0
    //jQuery wait plugin:
    $app['scripts']->add('jquery.wait', 'plugins/widgets/popover_ex/assets/jquery.wait.min.js', array('uikit'));
    //Marked:
    $app['scripts']->add('marked', 'plugins/widgets/popover_ex/assets/marked.min.js', array('uikit'));
    //Mailchimp for subscription:
    $app['scripts']->add('mailchimp', 'plugins/widgets/popover_ex/assets/jquery.formchimp.min.js', array('uikit'));
    //jQuery form validator http://www.formvalidator.net/:
    $app['scripts']->add('jquery-form-validator', 'https://cdnjs.cloudflare.com/ajax/libs/jquery-form-validator/2.3.20/jquery.form-validator.min.js', array('uikit'));
    //Underscore.js
    $app['scripts']->add('underscore', 'plugins/widgets/popover_ex/assets/underscore-min.js', array('uikit'));
    //Semantic version compare
    $app['scripts']->add('versioncompare', 'plugins/widgets/popover_ex/assets/versioncompare.min.js', array('uikit'));
    //Marked:
    $app['scripts']->add('replacer', 'plugins/widgets/popover_ex/assets/replacer.min.js', array('uikit'));
    //Generating dynamic update script:
    $plugin = new WidgetkitExPlugin($app);
    $app['scripts']->add('popover_ex.dynamic-updater', $plugin->generateUpdaterJS($app), array(), 'string');
}, 'request' => function ($event, $app) {
    $global = null;
    if (isset($app['request']) && isset($app['request']->request)) {
        $content = $app['request']->request->get('content');
        if (isset($content['data']['_widget']['data']['global'])) {
            $global = $content['data']['_widget']['data']['global'];
        }
    }
    if ($global) {
        //Global is set for valid requests like "Save" and "Save & Close"
        $plugin = new WidgetkitExPlugin($app);
        $plugin->saveGlobalSettings($global);
    }
}));
예제 #2
0
<?php

/*
PopoverEx plugin for Widgetkit 2.
Author: Ramil Valitov
E-mail: ramilvalitov@gmail.com
Web: http://www.valitov.me/
Git: https://github.com/rvalitov/widgetkit-popover-ex
*/
use WidgetkitEx\PopoverEx\WidgetkitExPlugin;
$plugin = new WidgetkitExPlugin($app);
?>

<div class="uk-grid uk-grid-divider uk-form uk-form-horizontal" data-uk-grid-margin>
    <div class="uk-width-medium-1-4">

        <div class="wk-panel-marginless">
            <ul class="uk-nav uk-nav-side" data-uk-switcher="{connect:'#nav-content'}">
                <li><a href="">{{'Popover' | trans}}</a></li>
                <li><a href="">{{'Media' | trans}}</a></li>
                <li><a href="">{{'Content' | trans}}</a></li>
                <li><a href="">{{'General' | trans}}</a></li>
				<li><a href="">{{'About' | trans}}</a></li>
            </ul>
        </div>

    </div>
    <div class="uk-width-medium-3-4">

        <ul id="nav-content" class="uk-switcher">
            <li>