@pitaya-components/app
Advanced tools
Comparing version 0.0.15 to 0.0.16
@@ -10,15 +10,6 @@ export interface PitayaConfigurationObject | ||
export declare class PitayaConfiguration | ||
{ | ||
get devBodyClass(): PitayaConfigurationObject["devBodyClass"]; | ||
get developmentEnabled(): PitayaConfigurationObject["developmentEnabled"]; | ||
get scrollHistoryMode(): PitayaConfigurationObject["scrollHistory"]["mode"]; | ||
} | ||
/** | ||
* Configures the Plugin | ||
*/ | ||
export declare class PitayaApp | ||
export declare class PitayaComponentConfiguration | ||
{ | ||
@@ -30,2 +21,8 @@ /** | ||
get devBodyClass(): PitayaConfigurationObject["devBodyClass"]; | ||
get developmentEnabled(): PitayaConfigurationObject["developmentEnabled"]; | ||
get scrollHistoryMode(): PitayaConfigurationObject["scrollHistory"]["mode"]; | ||
/** | ||
@@ -32,0 +29,0 @@ * Enables development. Optionally sets the devBodyClass. |
@@ -10,3 +10,6 @@ "use strict"; | ||
}; | ||
class PitayaConfiguration { | ||
class PitayaComponentConfiguration { | ||
constructor() { | ||
this.initialized = false; | ||
} | ||
get devBodyClass() { | ||
@@ -21,8 +24,2 @@ return config.devBodyClass; | ||
} | ||
} | ||
exports.PitayaConfiguration = PitayaConfiguration; | ||
class PitayaApp { | ||
constructor() { | ||
this.initialized = false; | ||
} | ||
enableDevelopment(bodyMarkerClass) { | ||
@@ -37,4 +34,4 @@ config.developmentEnabled = true; | ||
} | ||
exports.PitayaApp = PitayaApp; | ||
exports.PitayaComponentConfiguration = PitayaComponentConfiguration; | ||
//# sourceMappingURL=configuration.js.map |
@@ -88,3 +88,3 @@ "use strict"; | ||
if (currentInstance) { | ||
throw new Error("ERROR [Pitaya:App] It is not allowed to have multiple {PitayaApp}/<pi-app> custom elements at a time. You have first to detach the current one from the DOM."); | ||
throw new Error("ERROR [Pitaya:App] It is not allowed to have multiple {PiApp}/<pi-app> custom elements at a time. You have first to detach the current one from the DOM."); | ||
} | ||
@@ -91,0 +91,0 @@ currentInstance = this; |
@@ -32,3 +32,3 @@ "use strict"; | ||
let PiView = class PiView { | ||
constructor(_rootElement, _levelHistory, _queue, _router, _pitayaConfig) { | ||
constructor(_rootElement, _levelHistory, _queue, _router, _config) { | ||
var _a, _b, _c, _d; | ||
@@ -39,3 +39,3 @@ this._rootElement = _rootElement; | ||
this._router = _router; | ||
this._pitayaConfig = _pitayaConfig; | ||
this._config = _config; | ||
this._animationReady = false; | ||
@@ -87,3 +87,3 @@ this._isOnline = navigator.onLine; | ||
_handleScrollHistory() { | ||
const { scrollHistoryMode } = this._pitayaConfig; | ||
const { scrollHistoryMode } = this._config; | ||
const scrollHeight = scrollHistory.get(this._routeFragment); | ||
@@ -174,3 +174,3 @@ if (scrollHistoryMode === "never" || !scrollHeight) { | ||
aurelia_router_1.Router, | ||
configuration_1.PitayaConfiguration]) | ||
configuration_1.PitayaComponentConfiguration]) | ||
], PiView); | ||
@@ -177,0 +177,0 @@ exports.PiView = PiView; |
@@ -26,3 +26,3 @@ "use strict"; | ||
"under development"() { | ||
return aurelia_framework_1.Container.instance.get(configuration_1.PitayaConfiguration).developmentEnabled; | ||
return aurelia_framework_1.Container.instance.get(configuration_1.PitayaComponentConfiguration).developmentEnabled; | ||
} | ||
@@ -29,0 +29,0 @@ }; |
import { FrameworkConfiguration } from "aurelia-framework"; | ||
import { PitayaConfiguration } from "./configuration"; | ||
import { PitayaComponentConfiguration } from "./configuration"; | ||
export declare function configure( frameworkConfig: FrameworkConfiguration, callback?: ( config: PitayaConfiguration ) => void ): void; | ||
export declare function configure( frameworkConfig: FrameworkConfiguration, callback?: ( config: PitayaComponentConfiguration ) => void ): void; | ||
@@ -6,0 +6,0 @@ export * from "./elements/pi-app"; |
@@ -39,3 +39,3 @@ "use strict"; | ||
aurelia_typed_observable_plugin_1.usePropertyTypeForObservable(true); | ||
const config = aurelia_framework_1.Container.instance.get(configuration_1.PitayaApp); | ||
const config = aurelia_framework_1.Container.instance.get(configuration_1.PitayaComponentConfiguration); | ||
callback instanceof Function && callback(config); | ||
@@ -42,0 +42,0 @@ config.initialized = true; |
@@ -10,15 +10,6 @@ export interface PitayaConfigurationObject | ||
export declare class PitayaConfiguration | ||
{ | ||
get devBodyClass(): PitayaConfigurationObject["devBodyClass"]; | ||
get developmentEnabled(): PitayaConfigurationObject["developmentEnabled"]; | ||
get scrollHistoryMode(): PitayaConfigurationObject["scrollHistory"]["mode"]; | ||
} | ||
/** | ||
* Configures the Plugin | ||
*/ | ||
export declare class PitayaApp | ||
export declare class PitayaComponentConfiguration | ||
{ | ||
@@ -30,2 +21,8 @@ /** | ||
get devBodyClass(): PitayaConfigurationObject["devBodyClass"]; | ||
get developmentEnabled(): PitayaConfigurationObject["developmentEnabled"]; | ||
get scrollHistoryMode(): PitayaConfigurationObject["scrollHistory"]["mode"]; | ||
/** | ||
@@ -32,0 +29,0 @@ * Enables development. Optionally sets the devBodyClass. |
@@ -8,3 +8,6 @@ const config = { | ||
}; | ||
export class PitayaConfiguration { | ||
export class PitayaComponentConfiguration { | ||
constructor() { | ||
this.initialized = false; | ||
} | ||
get devBodyClass() { | ||
@@ -19,7 +22,2 @@ return config.devBodyClass; | ||
} | ||
} | ||
export class PitayaApp { | ||
constructor() { | ||
this.initialized = false; | ||
} | ||
enableDevelopment(bodyMarkerClass) { | ||
@@ -26,0 +24,0 @@ config.developmentEnabled = true; |
@@ -85,3 +85,3 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { | ||
if (currentInstance) { | ||
throw new Error("ERROR [Pitaya:App] It is not allowed to have multiple {PitayaApp}/<pi-app> custom elements at a time. You have first to detach the current one from the DOM."); | ||
throw new Error("ERROR [Pitaya:App] It is not allowed to have multiple {PiApp}/<pi-app> custom elements at a time. You have first to detach the current one from the DOM."); | ||
} | ||
@@ -88,0 +88,0 @@ currentInstance = this; |
@@ -23,3 +23,3 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { | ||
import { bindable, usePropertyTypeForBindable, usePropertyTypeForObservable } from "aurelia-typed-observable-plugin"; | ||
import { PitayaConfiguration } from "../configuration"; | ||
import { PitayaComponentConfiguration } from "../configuration"; | ||
import { NavigationLevelHistory } from "../elements/pi-app"; | ||
@@ -31,3 +31,3 @@ usePropertyTypeForBindable(true); | ||
let PiView = class PiView { | ||
constructor(_rootElement, _levelHistory, _queue, _router, _pitayaConfig) { | ||
constructor(_rootElement, _levelHistory, _queue, _router, _config) { | ||
var _a, _b, _c, _d; | ||
@@ -38,3 +38,3 @@ this._rootElement = _rootElement; | ||
this._router = _router; | ||
this._pitayaConfig = _pitayaConfig; | ||
this._config = _config; | ||
this._animationReady = false; | ||
@@ -86,3 +86,3 @@ this._isOnline = navigator.onLine; | ||
_handleScrollHistory() { | ||
const { scrollHistoryMode } = this._pitayaConfig; | ||
const { scrollHistoryMode } = this._config; | ||
const scrollHeight = scrollHistory.get(this._routeFragment); | ||
@@ -173,3 +173,3 @@ if (scrollHistoryMode === "never" || !scrollHeight) { | ||
Router, | ||
PitayaConfiguration]) | ||
PitayaComponentConfiguration]) | ||
], PiView); | ||
@@ -176,0 +176,0 @@ export { PiView }; |
@@ -13,3 +13,3 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
import { RedirectToRoute } from "aurelia-router"; | ||
import { PitayaConfiguration } from "../configuration"; | ||
import { PitayaComponentConfiguration } from "../configuration"; | ||
const httpClient = new HttpClient(); | ||
@@ -25,3 +25,3 @@ const logger = LogManager.getLogger("Pitaya:Decorators"); | ||
"under development"() { | ||
return Container.instance.get(PitayaConfiguration).developmentEnabled; | ||
return Container.instance.get(PitayaComponentConfiguration).developmentEnabled; | ||
} | ||
@@ -28,0 +28,0 @@ }; |
import { FrameworkConfiguration } from "aurelia-framework"; | ||
import { PitayaConfiguration } from "./configuration"; | ||
import { PitayaComponentConfiguration } from "./configuration"; | ||
export declare function configure( frameworkConfig: FrameworkConfiguration, callback?: ( config: PitayaConfiguration ) => void ): void; | ||
export declare function configure( frameworkConfig: FrameworkConfiguration, callback?: ( config: PitayaComponentConfiguration ) => void ): void; | ||
@@ -6,0 +6,0 @@ export * from "./elements/pi-app"; |
import { Container, PLATFORM } from "aurelia-framework"; | ||
import { coerceFunctions, usePropertyTypeForBindable, usePropertyTypeForObservable } from "aurelia-typed-observable-plugin"; | ||
import { PitayaApp } from "./configuration"; | ||
import { PitayaComponentConfiguration } from "./configuration"; | ||
let initialized = false; | ||
@@ -34,3 +34,3 @@ export function configure(frameworkConfig, callback) { | ||
usePropertyTypeForObservable(true); | ||
const config = Container.instance.get(PitayaApp); | ||
const config = Container.instance.get(PitayaComponentConfiguration); | ||
callback instanceof Function && callback(config); | ||
@@ -37,0 +37,0 @@ config.initialized = true; |
{ | ||
"name": "@pitaya-components/app", | ||
"version": "0.0.15", | ||
"version": "0.0.16", | ||
"description": "Aurelia plugin which helps building faster views and provides additional utility functionality.", | ||
@@ -5,0 +5,0 @@ "repository": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
129171
1799