This is a migrated thread and some comments may be shown as answers.

Multiple Layouts

2 Answers 72 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Kori
Top achievements
Rank 2
Kori asked on 12 Feb 2016, 04:18 PM

Is there a way (documented, sample code, etc to at least see how it might work) where I can use mutliple layouts? The majority of the app uses a drawer navigation, but the unauthenticated part of the app (first run, login) shouldn't use the drawer navigation and it shouldn't be accessible.

 I've created a layout which is no-nav and no-header like this:

1.<div data-role="layout" data-id="main-nonav-noheader">
2.    <!-- application views will be rendered here -->
3.</div>

And setting the first view to that layout works fine:

1.app.mobileApp = new kendo.mobile.Application(document.body, {
2.    skin: 'flat',
3.    initial: 'components/startView/view.html'
4.});

But you an easily drag the screen to reveal the drawer navigation, which I don't want to be possible.

It's made worse by the "startView" component using a scrollView to show the user four pages of "here's how this app works" before directing them to the login page. This "startView" is really only for new users who run the app for the first time, but generally they would either get logged in after using touchId/pin, or login again if the JWT token is expired.

Any ideas?

None of the samples seem to do anything complex in terms of layout, from what I can tell.

2 Answers, 1 is accepted

Sort by
0
Kori
Top achievements
Rank 2
answered on 12 Feb 2016, 04:35 PM

Oh, I see - I needed to set the data-views property on the drawer. Found on: http://docs.telerik.com/KENDO-UI/api/javascript/mobile/ui/drawer#configuration-views

Though, my suggestion would be to document this more on anything pertaining to drawers and layouts.

0
Tsvetina
Telerik team
answered on 17 Feb 2016, 01:11 PM
Hello Kori,

This property is described in the Drawer overview article here:
Associate Drawer with Remote Views

If you want the Kendo UI team to extend the explanation in this article, or add the information to other articles as well, you can write in their feedback portal.

Regards,
Tsvetina
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
Kori
Top achievements
Rank 2
Answers by
Kori
Top achievements
Rank 2
Tsvetina
Telerik team
Share this question
or