Add photo detection framework (#8)

Closes #5.

Reviewed-on: Georgi_Lab/ALVINN_f7#8
This commit is contained in:
2023-11-14 10:16:33 -07:00
parent 9eed19776f
commit fc6f26d469
16 changed files with 278 additions and 398 deletions

View File

@@ -1,9 +1,9 @@
import HomePage from '../pages/home.vue';
import AboutPage from '../pages/about.vue';
import DetectPage from '../pages/detect.vue';
import DynamicRoutePage from '../pages/dynamic-route.vue';
import RequestAndLoad from '../pages/request-and-load.vue';
import NotFoundPage from '../pages/404.vue';
var routes = [
@@ -15,59 +15,16 @@ var routes = [
path: '/about/',
component: AboutPage,
},
{
path: '/detect/:region/',
component: DetectPage,
},
{
path: '/dynamic-route/blog/:blogId/post/:postId/',
component: DynamicRoutePage,
},
{
path: '/request-and-load/user/:userId/',
async: function ({ router, to, resolve }) {
// App instance
var app = router.app;
// Show Preloader
app.preloader.show();
// User ID from request
var userId = to.params.userId;
// Simulate Ajax Request
setTimeout(function () {
// We got user data from request
var user = {
firstName: 'Vladimir',
lastName: 'Kharlampidi',
about: 'Hello, i am creator of Framework7! Hope you like it!',
links: [
{
title: 'Framework7 Website',
url: 'http://framework7.io',
},
{
title: 'Framework7 Forum',
url: 'http://forum.framework7.io',
},
]
};
// Hide Preloader
app.preloader.hide();
// Resolve route to load page
resolve(
{
component: RequestAndLoad,
},
{
props: {
user: user,
}
}
);
}, 1000);
},
},
{
path: '(.*)',
component: NotFoundPage,