Skip to content

Commit

Permalink
refactor!: New separate entry modules for each component. (#1351)
Browse files Browse the repository at this point in the history
* refactor(config): Updated tsconfig to standard format, and remove extraneous configs

* refactor(jest): switched test back to ng-cli, also alias angular2-text-mask

* chore: retest build

* chore: updating test results

* chore: update node version

* feat(Autocomplete): Autocomplete now works with ChipList (#1326)

* fix(Chips): update the ux for disabled chips (#1331)

-darken the opacity to improve readability
-update text color of disabled chips to look non-selectable
-remove the X icon to further confer that this chip is read-only

Co-authored-by: Michael Dill <[email protected]>

* feat(NonIdealState): Non Ideal Loading (#1334)

* Expanding non-ideal-state for use case with novo-loading

* Expanding non-ideal-state for use case with novo-loading

* Minor structure cleanup

* Changed message on example

* chore(ci): updating tokens

* chore(ci): Other Tokens Updated

* chore(): reverting commonjs tests

* fixed tests

* testing test summary

* tweaking test summary

* fix

* fix last attempt

* test

* fix tsconfig

* refactor(NgPackager): first step in tree-shaking

* refactor(style): almost all styles removed from novo-elements.scss

* BREAKING_CHANGES: Major SCSS updates

* fix(build): missing script for nx

* fix(build): Removing resize-observer-polyfill

* fix(build): weird build error in chips missing `includes`

* fixed all jest tests

* fix(build): bad styleUrls

* chore(build): updated test script

* chore(build): Remove copy-scss script as it is handled by ng-packgr now

* chore: forgot to remove script

* chore(fix): Moved snapshot publish back to root

Co-authored-by: Michael Dill <[email protected]>
Co-authored-by: Michael Dill <[email protected]>
Co-authored-by: antonyw89 <[email protected]>
  • Loading branch information
4 people authored Oct 17, 2022
1 parent 7b0df7f commit d74b1df
Show file tree
Hide file tree
Showing 2,694 changed files with 210,009 additions and 188,762 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/firebase-hosting-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,14 @@ jobs:
- name: Setup NodeJS
uses: actions/setup-node@v1
with:
node-version: 14.19.1
node-version: 14.19.3

- run: npm ci && npm run build:ci && npm run build:examples && npm run build:demo
- name: Install Dependencies
run: |
npm install -g nx && npm ci
- name: Building Projects
run: npm run build:demo

- name: Deploy preview
uses: FirebaseExtended/action-hosting-deploy@v0
Expand Down
23 changes: 22 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: CI

on: [pull_request]

permissions:
checks: write
pull-requests: write

jobs:
build:
name: Build & Test
Expand All @@ -15,14 +19,31 @@ jobs:
- name: Setup NodeJS
uses: actions/setup-node@v1
with:
node-version: 14.18.2
node-version: 14.19.1
- name: Install Dependencies
run: |
npm install
- name: Test
run: |
npm run lint
npm test
- name: Test Report
uses: dorny/test-reporter@v1
if: success() || failure()
with:
name: JEST Tests
path: reports/jest-*.xml
reporter: jest-junit
- uses: test-summary/action@v1
with:
paths: reports/jest-junit.xml
output: reports/summary.md
- name: Test Summary
run: cat reports/summary.md >> $GITHUB_STEP_SUMMARY
- uses: actions-cool/maintain-one-comment@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
body: $GITHUB_STEP_SUMMARY
- name: Build
run: |
npm run build:ci
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
node-version: 14.19.3
- name: Install Dependencies
run: |
npm ci
npm install -g nx && npm ci
- name: Building Projects
run: |
npm run build:ci
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ novo-elements.iml
/.sass-cache
/connect.lock
/coverage
/reports
/libpeerconnection.log
npm-debug.log
yarn-error.log
Expand Down
133 changes: 5 additions & 128 deletions angular.json
Original file line number Diff line number Diff line change
@@ -1,134 +1,11 @@
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"version": 1,
"$schema": "./node_modules/nx/schemas/workspace-schema.json",
"version": 2,
"newProjectRoot": "projects",
"projects": {
"novo-elements": {
"root": "projects/novo-elements",
"sourceRoot": "projects/novo-elements/src",
"projectType": "library",
"prefix": "lib",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:ng-packagr",
"options": {
"tsConfig": "projects/novo-elements/tsconfig.lib.json",
"project": "projects/novo-elements/ng-package.json"
},
"configurations": {
"production": {
"tsConfig": "projects/novo-elements/tsconfig.lib.prod.json"
}
}
},
"test": {
"builder": "@angular-builders/jest:run",
"options": {
"coverage": true
}
}
}
},
"novo-examples": {
"root": "projects/novo-examples",
"sourceRoot": "projects/novo-examples/src",
"projectType": "library",
"prefix": "lib",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:ng-packagr",
"options": {
"tsConfig": "projects/novo-examples/tsconfig.lib.json",
"project": "projects/novo-examples/ng-package.json"
},
"configurations": {
"production": {
"tsConfig": "projects/novo-examples/tsconfig.lib.prod.json"
}
}
},
"test": {
"builder": "@angular-devkit/build-angular:karma",
"options": {
"main": "projects/novo-examples/src/test.ts",
"tsConfig": "projects/novo-examples/tsconfig.spec.json",
"karmaConfig": "projects/novo-examples/karma.conf.js"
}
}
}
},
"demo": {
"root": "",
"sourceRoot": "projects/demo",
"projectType": "application",
"prefix": "novo-demo",
"schematics": {},
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"outputPath": "dist/demo",
"index": "projects/demo/index.html",
"main": "projects/demo/main.ts",
"polyfills": "projects/demo/polyfills.ts",
"tsConfig": "projects/demo/tsconfig.app.json",
"assets": ["projects/demo/favicon.ico", "projects/demo/assets"],
"styles": ["projects/demo/styles.scss"],
"stylePreprocessorOptions": {
"includePaths": ["projects/novo-elements/src"]
},
"scripts": [],
"vendorChunk": true,
"extractLicenses": false,
"buildOptimizer": false,
"sourceMap": true,
"optimization": false,
"namedChunks": true
},
"configurations": {
"production": {
"budgets": [
{
"type": "anyComponentStyle",
"maximumWarning": "6kb"
}
],
"fileReplacements": [
{
"replace": "projects/demo/environments/environment.ts",
"with": "projects/demo/environments/environment.prod.ts"
}
],
"optimization": true,
"outputHashing": "all",
"sourceMap": false,
"namedChunks": false,
"aot": false,
"extractLicenses": true,
"vendorChunk": false
}
},
"defaultConfiguration": ""
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"options": {
"browserTarget": "demo:build"
},
"configurations": {
"production": {
"browserTarget": "demo:build:production"
}
}
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "demo:build"
}
}
}
}
"novo-elements": "projects/elements",
"novo-examples": "projects/examples",
"demo": "projects/demo"
},
"defaultProject": "demo",
"cli": {
Expand Down
50 changes: 0 additions & 50 deletions copy-scss.js

This file was deleted.

19 changes: 0 additions & 19 deletions jest.config.js

This file was deleted.

5 changes: 5 additions & 0 deletions jest.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { getJestProjects } from '@nrwl/jest';

export default {
projects: getJestProjects(),
};
3 changes: 3 additions & 0 deletions jest.preset.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
const nxPreset = require('@nrwl/jest/preset').default;

module.exports = { ...nxPreset };
1 change: 0 additions & 1 deletion jest.setup.ts

This file was deleted.

52 changes: 52 additions & 0 deletions nx.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"affected": {
"defaultBase": "main"
},
"implicitDependencies": {
"angular.json": "*",
"package.json": {
"dependencies": "*",
"devDependencies": "*"
},
"nx.json": "*",
"tsconfig.*.json": "*",
"tsconfig.json": "*",
"tslint.json": "*"
},
"tasksRunnerOptions": {
"default": {
"runner": "nx/tasks-runners/default",
"options": {
"cacheableOperations": ["build", "lint", "test", "e2e"]
}
}
},
"targetDefaults": {
"build": {
"dependsOn": ["^build"]
}
},
"workspaceLayout": {
"appsDir": "projects",
"libsDir": "projects"
},
"cli": {
"analytics": false
},
"generators": {
"@nrwl/angular:application": {
"style": "css",
"linter": "eslint",
"unitTestRunner": "jest",
"e2eTestRunner": "cypress"
},
"@nrwl/angular:library": {
"linter": "eslint",
"unitTestRunner": "jest"
},
"@nrwl/angular:component": {
"style": "css"
}
},
"defaultProject": "demo"
}
Loading

0 comments on commit d74b1df

Please sign in to comment.