From da6e5ae10d0ce6b92b79707e830c33ad04d30b5d Mon Sep 17 00:00:00 2001 From: Vladimir Kharlampidi Date: Wed, 22 Mar 2023 19:18:50 +0300 Subject: [PATCH] feat(app): remove `id`, `version`, `language` app params and properties --- src/core/components/app/app-class.d.ts | 12 ------------ src/core/components/app/app-class.js | 9 --------- 2 files changed, 21 deletions(-) diff --git a/src/core/components/app/app-class.d.ts b/src/core/components/app/app-class.d.ts index d9027e0197..53857cc2ef 100644 --- a/src/core/components/app/app-class.d.ts +++ b/src/core/components/app/app-class.d.ts @@ -43,16 +43,10 @@ export interface Framework7EventsClass { export interface Framework7Parameters { /** App root element. If you main app layout is not a direct child of the then it is required to specify root element here. (default body) */ el?: string; - /** App bundle id.. (default io.framework7.testapp) */ - id?: string | 'io.framework7.testapp'; /** App name. Can be used by other components, e.g. as the default title for Dialog component.. (default Framework7) */ name?: string; - /** App version. Can be used by other components.. (default 1.0.0) */ - version?: string; /** App theme. Can be ios, md or auto. In case of auto it will use iOS theme for iOS devices and MD theme for all other devices.. (default 'auto') */ theme?: string; - /** App language. Can be used by other components. By default equal to the current browser/webview language (i.e. navigator.language).. */ - language?: string; /** Array with default routes to all views.. (default []) */ routes?: Router.RouteParameters[]; /** Enables dark mode, can be `false` (disabled), `true` (enabled) or `auto` (based on system preferences) */ @@ -131,16 +125,10 @@ export interface Framework7Events { } interface Framework7 extends Framework7Class { - /** App ID passed in parameters */ - id: string; /** App name passed in parameters */ name: string; - /** App version */ - version: string; /** App routes */ routes: Router.RouteParameters[]; - /** App language */ - language: string; /** App root HTML element */ el: HTMLElement; /** Dom7 instance with app root element */ diff --git a/src/core/components/app/app-class.js b/src/core/components/app/app-class.js index dbfe3ea676..390dbef73c 100644 --- a/src/core/components/app/app-class.js +++ b/src/core/components/app/app-class.js @@ -37,11 +37,8 @@ class Framework7 extends Framework7Class { // Default const defaults = { - version: '1.0.0', - id: 'io.framework7.myapp', el: 'body', theme: 'auto', - language: w.navigator.language, routes: [], name: 'Framework7', lazyModulesPath: null, @@ -80,16 +77,10 @@ class Framework7 extends Framework7Class { app.params = extend(defaults, params); extend(app, { - // App Id - id: app.params.id, // App Name name: app.params.name, - // App version - version: app.params.version, // Routes routes: app.params.routes, - // Lang - language: app.params.language, // Theme theme: (function getTheme() {