Skip to content

Commit

Permalink
*BREAKING CHANGE* feature(deploy): single core package. closes(#166 and
Browse files Browse the repository at this point in the history
#93) (#201)

* created NucleusModule with animations, forms and pipes in it

* stop exporting directive constants

* fixed imports/exports for rollup build (nucleus)

* added dialogs.module

* added expansion-panel.module

* added layout.module

* added loading.module

* added media.module

* added steps.module

* moved data-table.module into core.module

* update docs to state you can pull the module separatly or  inside Core

* added chips.module inside core.module

* missed a few imports for chips.module

* added file.module into core.mocule

* added json-formatter.module into core.module

* added paging.module into core.module

* remove charts from theming

* extracted markdown from core theming

* reorg styles and theming

* pullled search.module into core.module

* fixed demo imports to `core` and changed location of markdown-theme

* renamed nuclues.module into common.module

* fixed theming path

* adde TD_FORMS directives into common.module

* added theming for charts (back)
  • Loading branch information
emoralesb05 authored and kyleledbetter committed Dec 20, 2016
1 parent d73badb commit 81901b2
Show file tree
Hide file tree
Showing 170 changed files with 645 additions and 603 deletions.
2 changes: 1 addition & 1 deletion angular-cli.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"styles": [
"styles.scss",
"theme.scss",
"platform/core/styles/platform.scss"
"platform/core/common/platform.scss"
],
"scripts": [
"../node_modules/hammerjs/hammer.min.js",
Expand Down
16 changes: 2 additions & 14 deletions src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,11 @@ import { LayoutsModule } from './components/layouts/';
import { StyleGuideModule } from './components/style-guide/';
import { appRoutes, appRoutingProviders } from './app.routes';

import { CovalentCoreModule, TD_LOADING_ENTRY_COMPONENTS } from '../platform/core';
import { CovalentFileModule } from '../platform/file-upload';
import { CovalentCoreModule } from '../platform/core';
import { CovalentHighlightModule } from '../platform/highlight';
import { CovalentHttpModule } from '../platform/http';
import { CovalentMarkdownModule } from '../platform/markdown';
import { CovalentJsonFormatterModule } from '../platform/json-formatter';
import { CovalentChipsModule } from '../platform/chips';
import { CovalentChartsModule } from '../platform/charts';
import { CovalentDataTableModule } from '../platform/data-table';
import { CovalentPagingModule } from '../platform/paging';
import { CovalentSearchModule } from '../platform/search';

@NgModule({
declarations: [
Expand All @@ -33,22 +27,16 @@ import { CovalentSearchModule } from '../platform/search';
LayoutsModule,
StyleGuideModule,
CovalentCoreModule.forRoot(),
CovalentFileModule.forRoot(),
CovalentHttpModule.forRoot(),
CovalentHighlightModule.forRoot(),
CovalentMarkdownModule.forRoot(),
CovalentJsonFormatterModule.forRoot(),
CovalentChipsModule.forRoot(),
CovalentChartsModule.forRoot(),
CovalentDataTableModule.forRoot(),
CovalentPagingModule.forRoot(),
CovalentSearchModule.forRoot(),
appRoutes,
], // modules needed to run this module
providers: [
appRoutingProviders,
], // additional providers needed for this module
entryComponents: [ TD_LOADING_ENTRY_COMPONENTS ],
entryComponents: [ ],
bootstrap: [ DocsAppComponent ],
})
export class AppModule {}
4 changes: 2 additions & 2 deletions src/app/components/components/chips/chips.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,10 @@ <h3>Setup:</h3>
<p>Import the [CovalentChipsModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentChipsModule } from '@covalent/chips';
import { CovalentChipsModule } from '@covalent/core';
@NgModule({
imports: [
CovalentChipsModule.forRoot(),
CovalentChipsModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
12 changes: 0 additions & 12 deletions src/app/components/components/components.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,9 @@ import { SearchDemoComponent } from './search/search.component';
import { MaterialComponentsComponent } from './material-components/material-components.component';

import { CovalentCoreModule } from '../../../platform/core';
import { CovalentFileModule } from '../../../platform/file-upload';
import { CovalentHighlightModule } from '../../../platform/highlight';
import { CovalentMarkdownModule } from '../../../platform/markdown';
import { CovalentJsonFormatterModule } from '../../../platform/json-formatter';
import { CovalentChipsModule } from '../../../platform/chips';
import { CovalentChartsModule } from '../../../platform/charts';
import { CovalentDataTableModule } from '../../../platform/data-table';
import { CovalentPagingModule } from '../../../platform/paging';
import { CovalentSearchModule } from '../../../platform/search';

@NgModule({
declarations: [
Expand All @@ -59,15 +53,9 @@ import { CovalentSearchModule } from '../../../platform/search';
],
imports: [
CovalentCoreModule.forRoot(),
CovalentFileModule.forRoot(),
CovalentHighlightModule.forRoot(),
CovalentMarkdownModule.forRoot(),
CovalentJsonFormatterModule.forRoot(),
CovalentChipsModule.forRoot(),
CovalentChartsModule.forRoot(),
CovalentDataTableModule.forRoot(),
CovalentPagingModule.forRoot(),
CovalentSearchModule.forRoot(),
componentsRoutes,
],
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ <h4 class="md-subhead">with custom headings, columns, and inline editing</h4>
<p>Typescript:</p>
<td-highlight lang="typescript">
<![CDATA[
import { ITdDataTableColumn } from '@covalent/data-table';
import { ITdDataTableColumn } from '@covalent/core';
import { TdDialogService } from '@covalent/core';
...
})
Expand Down Expand Up @@ -132,7 +132,7 @@ <h3 class="md-title">Basic Data Table</h3>
<p>Typescript:</p>
<td-highlight lang="typescript">
<![CDATA[
import { ITdDataTableColumn } from '@covalent/data-table';
import { ITdDataTableColumn } from '@covalent/core';
...
})
export class Demo {
Expand Down Expand Up @@ -256,8 +256,8 @@ <h4 class="md-subhead">Paging Bar / Search Box / Sortable components</h4>
<p>Typescript:</p>
<td-highlight lang="typescript">
<![CDATA[
import { TdDataTableService, TdDataTableSortingOrder, ITdDataTableSortChangeEvent, ITdDataTableColumn } from '@covalent/data-table';
import { IPageChangeEvent } from '@covalent/paging';
import { TdDataTableService, TdDataTableSortingOrder, ITdDataTableSortChangeEvent, ITdDataTableColumn } from '@covalent/core';
import { IPageChangeEvent } from '@covalent/core';
...
})
export class Demo {
Expand Down Expand Up @@ -375,7 +375,7 @@ <h3>Example:</h3>
<p>Typescript:</p>
<td-highlight lang="typescript">
<![CDATA[
import { ITdDataTableColumn } from '@covalent/data-table';
import { ITdDataTableColumn } from '@covalent/core';
...
})
export class Demo {
Expand All @@ -395,10 +395,10 @@ <h3>Setup:</h3>
<p>Import the [CovalentDataTableModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentDataTableModule } from '@covalent/data-table';
import { CovalentDataTableModule } from '@covalent/core';
@NgModule({
imports: [
CovalentDataTableModule.forRoot(),
CovalentDataTableModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { Component, OnInit } from '@angular/core';

import { TdDataTableSortingOrder, TdDataTableService,
ITdDataTableSortChangeEvent, ITdDataTableColumn } from '../../../../platform/data-table';
import { IPageChangeEvent } from '../../../../platform/paging';
ITdDataTableSortChangeEvent, ITdDataTableColumn } from '../../../../platform/core';
import { IPageChangeEvent } from '../../../../platform/core';
import { TdDialogService } from '../../../../platform/core';

const NUMBER_FORMAT: (v: any) => any = (v: number) => v;
Expand Down
6 changes: 3 additions & 3 deletions src/app/components/components/dialogs/dialogs.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -89,14 +89,14 @@ <h3>Example(after setup):</h3>
]]>
</td-highlight>
<h3>Setup:</h3>
<p>Import the [CovalentCoreModule] using the <code>forRoot()</code> method:</p>
<p>Import the [CovalentDialogsModule] using the <code>forRoot()</code> method:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentCoreModule } from '@covalent/core';
import { CovalentDialogsModule } from '@covalent/core';

@NgModule({
imports: [
CovalentCoreModule.forRoot(),
CovalentDialogsModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -232,13 +232,13 @@ <h3>Example:</h3>
]]>
</td-highlight>
<h3>Setup:</h3>
<p>Import the [CovalentCoreModule] using the <code>forRoot()</code> method in your NgModule:</p>
<p>Import the [CovalentExpansionPanelModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentCoreModule } from '@covalent/core';
import { CovalentExpansionPanelModule } from '@covalent/core';
@NgModule({
imports: [
CovalentCoreModule.forRoot(),
CovalentExpansionPanelModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@ <h3>Setup:</h3>
<td-highlight lang="typescript">
<![CDATA[
import { HttpModule } from '@angular/http';
import { CovalentFileModule } from '@covalent/file-upload';
import { CovalentFileModule } from '@covalent/core';
@NgModule({
imports: [
HttpModule, /* or CovalentCoreModule.forRoot() */
CovalentFileModule.forRoot(),
HttpModule,
CovalentFileModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down Expand Up @@ -205,7 +205,7 @@ <h3>Example:</h3>
<p>Typescript:</p>
<td-highlight lang="typescript">
<![CDATA[
import { TdFileService, IUploadOptions } from '@covalent/file-upload';
import { TdFileService, IUploadOptions } from '@covalent/core';
...
})
export class Demo {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@ <h3>Setup:</h3>
<p>Import the [CovalentJsonFormatterModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentJsonFormatterModule } from '@covalent/json-formatter';
import { CovalentJsonFormatterModule } from '@covalent/core';
@NgModule({
imports: [
CovalentJsonFormatterModule.forRoot(),
CovalentJsonFormatterModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
7 changes: 3 additions & 4 deletions src/app/components/components/loading/loading.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -125,17 +125,16 @@ <h3>Example(after setup):</h3>
]]>
</td-highlight>
<h3>Setup:</h3>
<p>Import the [CovalentCoreModule] using the <code>forRoot()</code> method and set [TD_LOADING_ENTRY_COMPONENTS] as 'entryComponents' in your NgModule:</p>
<p>Import the [CovalentLoadingModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentCoreModule, TD_LOADING_ENTRY_COMPONENTS } from '@covalent/core';
import { CovalentLoadingModule } from '@covalent/core';

@NgModule({
imports: [
CovalentCoreModule.forRoot(),
CovalentLoadingModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
entryComponents: [ TD_LOADING_ENTRY_COMPONENTS ],
...
})
export class MyModule {}
Expand Down
6 changes: 3 additions & 3 deletions src/app/components/components/media/media.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -88,13 +88,13 @@ <h3>Example:</h3>
<p>Note: Always unsubscribe from [Observable] objects when not using them anymore.</p>
<p>A good way of doing it is in the <code>ngOnDestroy</code> component life-cycle hook provided by the [OnDestroy] interface.</p>
<h3>Setup:</h3>
<p>Import the [CovalentCoreModule] using the <code>forRoot()</code> method in your NgModule:</p>
<p>Import the [CovalentMediaModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentCoreModule } from '@covalent/core';
import { CovalentMediaModule } from '@covalent/core';
@NgModule({
imports: [
CovalentCoreModule.forRoot(),
CovalentMediaModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
6 changes: 3 additions & 3 deletions src/app/components/components/paging/paging.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ <h3>Example:</h3>
<p>Typescript:</p>
<td-highlight lang="typescript">
<![CDATA[
import { IPageChangeEvent } from '@covalent/paging';
import { IPageChangeEvent } from '@covalent/core';
...
})
export class Demo {
Expand All @@ -88,10 +88,10 @@ <h3>Setup:</h3>
<p>Import the [CovalentPagingModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentPagingModule } from '@covalent/paging';
import { CovalentPagingModule } from '@covalent/core';
@NgModule({
imports: [
CovalentPagingModule.forRoot(),
CovalentPagingModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
2 changes: 1 addition & 1 deletion src/app/components/components/paging/paging.component.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Component } from '@angular/core';

import { IPageChangeEvent } from '../../../../platform/paging';
import { IPageChangeEvent } from '../../../../platform/core';

@Component({
selector: 'paging-demo',
Expand Down
4 changes: 2 additions & 2 deletions src/app/components/components/search/search.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@ <h3>Setup:</h3>
<p>Import the [CovalentSearchModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentSearchModule } from '@covalent/search';
import { CovalentSearchModule } from '@covalent/core';
@NgModule({
imports: [
CovalentSearchModule.forRoot(),
CovalentSearchModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
1 change: 0 additions & 1 deletion src/app/components/components/steps/index.ts

This file was deleted.

6 changes: 3 additions & 3 deletions src/app/components/components/steps/steps.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,13 @@ <h3>Example:</h3>
]]>
</td-highlight>
<h3>Setup:</h3>
<p>Import the [CovalentCoreModule] using the <code>forRoot()</code> method in your NgModule:</p>
<p>Import the [CovalentStepsModule] using the <code>forRoot()</code> method in your NgModule:</p>
<td-highlight lang="typescript">
<![CDATA[
import { CovalentCoreModule } from '@covalent/core';
import { CovalentStepsModule } from '@covalent/core';
@NgModule({
imports: [
CovalentCoreModule.forRoot(),
CovalentStepsModule.forRoot(), // or CovalentCoreModule.forRoot() (included inside of it)
...
],
...
Expand Down
2 changes: 1 addition & 1 deletion src/app/components/docs/theme/theme.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ <h3>SCSS Variables</h3>
<p>Simply edit the /theme.scss file and update these SCSS variables:</p>
<td-highlight lang="scss">
@import '~@angular/material/core/theming/all-theme';
@import '~@covalent/core/styles/theming/all-theme';
@import '~@covalent/core/theming/all-theme';
// Plus imports for other components in your app.

// Include the base styles for Angular Material core. We include this here so that you only
Expand Down
5 changes: 2 additions & 3 deletions src/platform/charts/_charts-theme.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@import '../../../node_modules/@angular/material/core/theming/theming';

@mixin td-charts-theme($theme) {
@mixin covalent-charts-theme($theme) {
$foreground: map-get($theme, foreground);
td-charts {
text {
Expand All @@ -24,5 +24,4 @@
stroke: md-color($foreground, divider);
}
}
}

}
2 changes: 2 additions & 0 deletions src/platform/charts/charts.component.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@import '../../../node_modules/@angular/material/core/theming/theming';

:host {
display: block;
}
Expand Down
2 changes: 0 additions & 2 deletions src/platform/chips/index.ts

This file was deleted.

Loading

0 comments on commit 81901b2

Please sign in to comment.