-
Notifications
You must be signed in to change notification settings - Fork 159
Open
Description
The push content feature doesn't appear to work properly. With the code below it works as expected but once you remove the second pageslide block, the ps-push just does the default sliding.
Am I missing something?
I was running Angular 1.4 but also reverted and tried 1.3.13 and still the same result.
This is is the code (same as the example minus a bunch of the buttons):
<!-- MAIN CONTENT -->
<div id="main_content_wrap" class="outer" style="padding:20px">
<header>
<h1>
<a name="angularjs-pageslide-directive" class="anchor" href="#angularjs-pageslide-directive"><span class="octicon octicon-link"></span></a>AngularJS Pageslide directive
</h1>
</header>
<section id="main_content" class="inner">
<p>
An <a href="http://angularjs.org/">AngularJS</a> directive which slides another panel over your browser to reveal an additional interaction pane.<br/>
It does all the css manipulation needed to position your content off canvas with html attibutes and it does not depend on jQuery
</p>
<h3>Push content</h3>
<div ng-controller="pageslideCtrl">
<a class="tiny button" href="" ng-click="toggle()">Open Sidebar</a>
<div pageslide ps-open="checked" ps-side="left" ps-push="true" >
<div style="padding:20px" id="demo-right">
<h2>Hello Pagesliderrrr</h2>
<p>Put here whatever you want</p>
<a ng-click="toggle()" class="button" >Close</a>
</div>
</div>
</div>
<!-- Remove this block and it no longer pushes the page content -->
<h3>Squeeze content</h3>
<div ng-controller="pageslideCtrl">
<a class="tiny button" href="" ng-click="toggle()">Open Sidebar</a>
<div pageslide ps-open="checked" ps-side="left" ps-squeeze="true" ps-cloak="true">
<div style="padding:20px" id="demo-right2">
<h2>I Don't Get it</h2>
<p>Why does this pageslide element need to be here for the previous one to push content?</p>
</div>
</div>
</div>
<br/>
</section>
</div>
nothing fancy in the controller either
.controller('pageslideCtrl', function ($scope) {
$scope.checked = false; // This will be binded using the ps-open attribute
$scope.toggle = function() {
$scope.checked = !$scope.checked;
}
});
Metadata
Metadata
Assignees
Labels
No labels