From 0f48f6ce85f1c499a31fe3173d0fa7146b6fa48e Mon Sep 17 00:00:00 2001 From: Arman Ozak Date: Wed, 17 Jun 2020 19:26:11 +0300 Subject: [PATCH] feat: delete legacy setting management config --- .../setting-management-config/README.md | 3 -- .../setting-management-config/jest.config.js | 6 --- .../setting-management-config/ng-package.json | 7 ---- .../setting-management-config/package.json | 12 ------ .../setting-management-config.service.ts | 37 ------------------- .../lib/setting-management-config.module.ts | 8 ---- .../src/public-api.ts | 1 - .../tsconfig.lib.json | 19 ---------- .../tsconfig.lib.prod.json | 6 --- .../tsconfig.spec.json | 11 ------ .../setting-management-config/tslint.json | 17 --------- 11 files changed, 127 deletions(-) delete mode 100644 npm/ng-packs/packages/setting-management-config/README.md delete mode 100644 npm/ng-packs/packages/setting-management-config/jest.config.js delete mode 100644 npm/ng-packs/packages/setting-management-config/ng-package.json delete mode 100644 npm/ng-packs/packages/setting-management-config/package.json delete mode 100644 npm/ng-packs/packages/setting-management-config/src/lib/services/setting-management-config.service.ts delete mode 100644 npm/ng-packs/packages/setting-management-config/src/lib/setting-management-config.module.ts delete mode 100644 npm/ng-packs/packages/setting-management-config/src/public-api.ts delete mode 100644 npm/ng-packs/packages/setting-management-config/tsconfig.lib.json delete mode 100644 npm/ng-packs/packages/setting-management-config/tsconfig.lib.prod.json delete mode 100644 npm/ng-packs/packages/setting-management-config/tsconfig.spec.json delete mode 100644 npm/ng-packs/packages/setting-management-config/tslint.json diff --git a/npm/ng-packs/packages/setting-management-config/README.md b/npm/ng-packs/packages/setting-management-config/README.md deleted file mode 100644 index 7bd9716004..0000000000 --- a/npm/ng-packs/packages/setting-management-config/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# @abp/ng.setting-management.config - -[docs.abp.io](https://docs.abp.io) diff --git a/npm/ng-packs/packages/setting-management-config/jest.config.js b/npm/ng-packs/packages/setting-management-config/jest.config.js deleted file mode 100644 index 77ce8a5dfa..0000000000 --- a/npm/ng-packs/packages/setting-management-config/jest.config.js +++ /dev/null @@ -1,6 +0,0 @@ -const jestConfig = require('../../jest.config'); - -module.exports = { - ...jestConfig, - name: 'setting-management-config', -}; diff --git a/npm/ng-packs/packages/setting-management-config/ng-package.json b/npm/ng-packs/packages/setting-management-config/ng-package.json deleted file mode 100644 index 95273dc0a7..0000000000 --- a/npm/ng-packs/packages/setting-management-config/ng-package.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "$schema": "../../node_modules/ng-packagr/ng-package.schema.json", - "dest": "../../dist/setting-management-config", - "lib": { - "entryFile": "src/public-api.ts" - } -} diff --git a/npm/ng-packs/packages/setting-management-config/package.json b/npm/ng-packs/packages/setting-management-config/package.json deleted file mode 100644 index b846a57e29..0000000000 --- a/npm/ng-packs/packages/setting-management-config/package.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "name": "@abp/ng.setting-management.config", - "version": "2.9.0", - "homepage": "https://abp.io", - "repository": { - "type": "git", - "url": "https://github.com/abpframework/abp.git" - }, - "publishConfig": { - "access": "public" - } -} diff --git a/npm/ng-packs/packages/setting-management-config/src/lib/services/setting-management-config.service.ts b/npm/ng-packs/packages/setting-management-config/src/lib/services/setting-management-config.service.ts deleted file mode 100644 index a5b319ccb1..0000000000 --- a/npm/ng-packs/packages/setting-management-config/src/lib/services/setting-management-config.service.ts +++ /dev/null @@ -1,37 +0,0 @@ -import { Injectable, Injector } from '@angular/core'; -import { addAbpRoutes, eLayoutType, PatchRouteByName, ABP } from '@abp/ng.core'; -import { getSettingTabs } from '@abp/ng.theme.shared'; -import { Store } from '@ngxs/store'; -import { eSettingManagementRouteNames } from '@abp/ng.setting-management'; - -@Injectable({ - providedIn: 'root', -}) -export class SettingManagementConfigService { - get store(): Store { - return this.injector.get(Store); - } - - constructor(private injector: Injector) { - const route = { - name: eSettingManagementRouteNames.Settings, - path: 'setting-management', - parentName: 'AbpUiNavigation::Menu:Administration', - requiredPolicy: 'AbpAccount.SettingManagement', - layout: eLayoutType.application, - order: 6, - iconClass: 'fa fa-cog', - } as ABP.FullRoute; - - addAbpRoutes(route); - - setTimeout(() => { - const tabs = getSettingTabs(); - if (!tabs || !tabs.length) { - this.store.dispatch( - new PatchRouteByName('AbpSettingManagement::Settings', { ...route, invisible: true }), - ); - } - }); - } -} diff --git a/npm/ng-packs/packages/setting-management-config/src/lib/setting-management-config.module.ts b/npm/ng-packs/packages/setting-management-config/src/lib/setting-management-config.module.ts deleted file mode 100644 index c11e712fa4..0000000000 --- a/npm/ng-packs/packages/setting-management-config/src/lib/setting-management-config.module.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { NgModule, APP_INITIALIZER } from '@angular/core'; -import { SettingManagementConfigService } from './services/setting-management-config.service'; -import { noop } from '@abp/ng.core'; - -@NgModule({ - providers: [{ provide: APP_INITIALIZER, deps: [SettingManagementConfigService], useFactory: noop, multi: true }], -}) -export class SettingManagementConfigModule {} diff --git a/npm/ng-packs/packages/setting-management-config/src/public-api.ts b/npm/ng-packs/packages/setting-management-config/src/public-api.ts deleted file mode 100644 index 236ed82079..0000000000 --- a/npm/ng-packs/packages/setting-management-config/src/public-api.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './lib/setting-management-config.module'; diff --git a/npm/ng-packs/packages/setting-management-config/tsconfig.lib.json b/npm/ng-packs/packages/setting-management-config/tsconfig.lib.json deleted file mode 100644 index 4f48db2e46..0000000000 --- a/npm/ng-packs/packages/setting-management-config/tsconfig.lib.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "extends": "../../tsconfig.prod.json", - "compilerOptions": { - "outDir": "../../out-tsc/lib", - "target": "es2015", - "declaration": true, - "inlineSources": true, - "types": [], - "lib": ["dom", "es2018"] - }, - "angularCompilerOptions": { - "skipTemplateCodegen": true, - "strictMetadataEmit": true, - "fullTemplateTypeCheck": true, - "strictInjectionParameters": true, - "enableResourceInlining": true - }, - "exclude": ["src/test.ts", "**/*.spec.ts"] -} diff --git a/npm/ng-packs/packages/setting-management-config/tsconfig.lib.prod.json b/npm/ng-packs/packages/setting-management-config/tsconfig.lib.prod.json deleted file mode 100644 index b1d501abbc..0000000000 --- a/npm/ng-packs/packages/setting-management-config/tsconfig.lib.prod.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "extends": "./tsconfig.lib.json", - "angularCompilerOptions": { - "enableIvy": false - } -} \ No newline at end of file diff --git a/npm/ng-packs/packages/setting-management-config/tsconfig.spec.json b/npm/ng-packs/packages/setting-management-config/tsconfig.spec.json deleted file mode 100644 index 02f312c262..0000000000 --- a/npm/ng-packs/packages/setting-management-config/tsconfig.spec.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "extends": "../../tsconfig.prod.json", - "compilerOptions": { - "emitDecoratorMetadata": true, - "esModuleInterop": true, - "outDir": "../../dist/out-tsc", - "module": "commonjs", - "types": ["jest", "node"] - }, - "include": ["**/*.spec.ts", "**/*.d.ts"] -} diff --git a/npm/ng-packs/packages/setting-management-config/tslint.json b/npm/ng-packs/packages/setting-management-config/tslint.json deleted file mode 100644 index 8c3919ea62..0000000000 --- a/npm/ng-packs/packages/setting-management-config/tslint.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "extends": "../../tslint.json", - "rules": { - "directive-selector": [ - true, - "attribute", - "abp", - "camelCase" - ], - "component-selector": [ - true, - "element", - "abp", - "kebab-case" - ] - } -}