Commit 41218efe authored by Kevin Yumang's avatar Kevin Yumang

SERV-2286 - looper element added

parent b141a7d7
{{-- Layout Reference --}}
@extends('Limitless::Help.Layout.Master')
@section('Limitless::Content')
@Limitless::CardStart(['title' => "Description", 'icon' => 'icon-info22'])
@Limitless::Looper(rand(1,5))
@Limitless::CardStop
@stop
\ No newline at end of file
@for ($i = 0, $i < $limit; $i++)
\ No newline at end of file
@endfor
\ No newline at end of file
......@@ -39,6 +39,7 @@
@Limitless::SideNavMenuItem(['url' => '?page=Element.Divider', 'target' => '_self', 'icon' => 'icon-minus2', 'title' => 'Divider'])
@Limitless::SideNavMenuItem(['url' => '?page=Element.Legend', 'target' => '_self', 'icon' => 'icon-vcard', 'title' => 'Legend'])
@Limitless::SideNavMenuItem(['url' => '?page=Element.LoremIpsum', 'target' => '_self', 'icon' => 'icon-bubble-lines3', 'title' => 'Lorem Ipsum'])
@Limitless::SideNavMenuItem(['url' => '?page=Looper', 'target' => '_self', 'icon' => 'icon-loop3', 'title' => 'Looper'])
@Limitless::SideNavMenuItem(['url' => '?page=Modal', 'target' => '_self', 'icon' => 'icon-stack', 'title' => 'Modal'])
@Limitless::SideNavMenuItem(['url' => '?page=Element.RandomSelect', 'target' => '_self', 'icon' => 'icon-shuffle', 'title' => 'Random Select'])
......
<?php
/*
|------------------------------------------------------------------------------------------------
| Information
|------------------------------------------------------------------------------------------------
|
| This file is beautified by the command "sidekick:CodebeautifierCommand" of the ceetrox
| sidekick package.
|
| Author: Kevin Almond Roe Yumang <kevin.yumang@itmax.email>
| Update: 2022-06-30 02:31:57
|
*/
namespace Ceetrox\Sidekick\Views\Limitless\Looper;
/*
|------------------------------------------------------------------------------------------------
| Dependencies
|------------------------------------------------------------------------------------------------
*/
use View;
/*
|------------------------------------------------------------------------------------------------
| Class "Config"
|------------------------------------------------------------------------------------------------
*/
class Config
{
public $methodAllocation = [
'Limitless::LooperStart' => 'looperStart',
'Limitless::LooperEnd' => 'looperEnd',
];
/*
|--------------------------------------------------------------------------------------------
| Method "looperStart"
|--------------------------------------------------------------------------------------------
*/
public function looperStart($limit)
{
return View('Limitless::Looper.Start')
->withLimit($limit ?? 1);
}
/*
|--------------------------------------------------------------------------------------------
| Method "looperStop"
|--------------------------------------------------------------------------------------------
*/
public function looperStop($parameters)
{
return View('Limitless::Looper.Stop');
}
}
{{-- Layout Reference --}}
@extends('Limitless::Help.Layout.Master')
@section('Limitless::Content')
@Limitless::CardStart(['title' => "Description", 'icon' => 'icon-info22'])
@Limitless::LooperStart(5)
{{ rand(1,10) }}
@Limitless::LooperStop
@Limitless::CardStop
@stop
\ No newline at end of file
@for ($i = 0, $i < $limit; $i++)
\ No newline at end of file
@endfor
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment