Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
c09bb18
feat(dashboard): add boilerplate library
alexander-lloyd Jun 27, 2021
26004b9
feat(dashboard): add dashboard boilerplate
alexander-lloyd Jul 17, 2021
c9e9436
feat: add dashboard boilerplate
alexander-lloyd Jul 17, 2021
6d249fb
fix(dashboard): move footer and sidebar
alexander-lloyd Jul 17, 2021
0b1e9d5
feat(dashboard): add sidebar
alexander-lloyd Jul 17, 2021
162cd7b
feat(dashboard): mobile optimise
alexander-lloyd Jul 17, 2021
4428414
feat(button): add click and mouseup event emitters
alexander-lloyd Jul 17, 2021
5ebd734
feat(dashboard): close sidebar when user clicks off
alexander-lloyd Jul 18, 2021
81f74ef
chore(angular): upgrade angular to 12.1.0
alexander-lloyd Jul 18, 2021
dad7201
fix(button): remove button output events
alexander-lloyd Jul 18, 2021
67aab51
feat(dashboard): add dashboard content
alexander-lloyd Jul 18, 2021
4864282
feat(favourite): add favourite boilerplate
alexander-lloyd Jul 18, 2021
2d5da81
feat(dashboard): add dashboard footer and dashboard footer item
alexander-lloyd Jul 25, 2021
38cb2b0
fix(dashboard): styling
alexander-lloyd Jul 25, 2021
a3cee71
feat(favourite): add favourites app
alexander-lloyd Jul 25, 2021
4fad220
feat(dashboard): update style
alexander-lloyd Aug 3, 2021
9292bc8
feat(favourite): add icons
alexander-lloyd Aug 3, 2021
2e11399
feat(favourite): style search input
alexander-lloyd Aug 3, 2021
c067849
feat(dashboard): move search to separate component
alexander-lloyd Aug 7, 2021
b1600b9
feat(favourite): add bookmark urlformat
alexander-lloyd Aug 31, 2021
985e4e5
Optimised images with calibre/image-actions
github-actions[bot] Aug 31, 2021
8ac2ff6
fix(favourite): fix regex
alexander-lloyd Aug 31, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,9 @@ module.exports = {
extends: [
'plugin:@typescript-eslint/eslint-recommended',
'plugin:@typescript-eslint/recommended',
'plugin:import/typescript'
'plugin:import/typescript',
'plugin:@nrwl/nx/angular',
'plugin:@angular-eslint/template/process-inline-templates'
],
rules: {
'@angular-eslint/component-class-suffix': 'error',
Expand Down
184 changes: 163 additions & 21 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,6 @@
"projects": {
"todo": {
"projectType": "application",
"schematics": {
"@nrwl/angular:component": {
"style": "scss"
}
},
"root": "apps/todo",
"sourceRoot": "apps/todo/src",
"prefix": "al",
Expand Down Expand Up @@ -130,13 +125,7 @@
"lint": {
"builder": "@nrwl/linter:eslint",
"options": {
"lintFilePatterns": [
"apps/todo/src/main.ts",
"apps/todo/src/polyfills.ts",
"apps/todo/**/*.spec.ts",
"apps/todo/**/*.d.ts",
"apps/todo/src/test-setup.ts"
]
"lintFilePatterns": ["apps/todo/src/**/*.ts"]
}
},
"test": {
Expand Down Expand Up @@ -191,6 +180,120 @@
}
}
},
"favourite": {
"projectType": "application",
"root": "apps/favourite",
"sourceRoot": "apps/favourite/src",
"prefix": "al",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"outputPath": "dist/apps/favourite",
"index": "apps/favourite/src/index.html",
"main": "apps/favourite/src/main.ts",
"polyfills": "apps/favourite/src/polyfills.ts",
"tsConfig": "apps/favourite/tsconfig.app.json",
"inlineStyleLanguage": "scss",
"assets": [
"apps/favourite/src/favicon.ico",
"apps/favourite/src/assets"
],
"styles": ["apps/favourite/src/styles.scss"],
"scripts": []
},
"configurations": {
"production": {
"budgets": [
{
"type": "initial",
"maximumWarning": "500kb",
"maximumError": "1mb"
},
{
"type": "anyComponentStyle",
"maximumWarning": "2kb",
"maximumError": "4kb"
}
],
"fileReplacements": [
{
"replace": "apps/favourite/src/environments/environment.ts",
"with": "apps/favourite/src/environments/environment.prod.ts"
}
],
"outputHashing": "all"
},
"development": {
"buildOptimizer": false,
"optimization": false,
"vendorChunk": true,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
}
},
"defaultConfiguration": "production"
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"browserTarget": "favourite:build:production"
},
"development": {
"browserTarget": "favourite:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "favourite:build"
}
},
"lint": {
"builder": "@nrwl/linter:eslint",
"options": {
"lintFilePatterns": ["apps/favourite/src/**/*.ts"]
}
},
"test": {
"builder": "@nrwl/jest:jest",
"outputs": ["coverage/apps/favourite"],
"options": {
"jestConfig": "apps/favourite/jest.config.js"
}
}
}
},
"favourite-e2e": {
"root": "apps/favourite-e2e",
"sourceRoot": "apps/favourite-e2e/src",
"projectType": "application",
"architect": {
"e2e": {
"builder": "@nrwl/cypress:cypress",
"options": {
"cypressConfig": "apps/favourite-e2e/cypress.json",
"tsConfig": "apps/favourite-e2e/tsconfig.e2e.json",
"devServerTarget": "favourite:serve:development"
},
"configurations": {
"production": {
"devServerTarget": "favourite:serve:production"
}
}
},
"lint": {
"builder": "@nrwl/linter:eslint",
"options": {
"lintFilePatterns": ["apps/favourite-e2e/**/*.{js,ts}"]
}
}
}
},
"logger": {
"projectType": "library",
"root": "libs/logger",
Expand Down Expand Up @@ -324,13 +427,7 @@
"lint": {
"builder": "@nrwl/linter:eslint",
"options": {
"lintFilePatterns": [
"apps/spotify-player/src/main.ts",
"apps/spotify-player/src/polyfills.ts",
"apps/spotify-player/**/*.spec.ts",
"apps/spotify-player/**/*.d.ts",
"apps/spotify-player/src/test-setup.ts"
]
"lintFilePatterns": ["apps/spotify-player/src/**/*.ts"]
}
},
"test": {
Expand Down Expand Up @@ -524,6 +621,44 @@
}
}
},
"dashboard-components": {
"projectType": "library",
"root": "libs/components/dashboard",
"sourceRoot": "libs/components/dashboard/src",
"prefix": "al",
"architect": {
"build": {
"builder": "@nrwl/angular:package",
"options": {
"tsConfig": "libs/components/dashboard/tsconfig.lib.json",
"project": "libs/components/dashboard/ng-package.json",
"buildableProjectDepsInPackageJsonType": "dependencies"
},
"configurations": {
"production": {
"tsConfig": "libs/components/dashboard/tsconfig.lib.prod.json"
},
"development": {
"tsConfig": "libs/components/dashboard/tsconfig.lib.json"
}
},
"defaultConfiguration": "production"
},
"test": {
"builder": "@nrwl/jest:jest",
"outputs": ["coverage/libs/components/dashboard"],
"options": {
"jestConfig": "libs/components/dashboard/jest.config.js"
}
},
"lint": {
"builder": "@nrwl/linter:eslint",
"options": {
"lintFilePatterns": ["libs/components/dashboard/src/**/*.ts"]
}
}
}
},
"history": {
"root": "libs/history",
"sourceRoot": "libs/history/src",
Expand Down Expand Up @@ -572,19 +707,26 @@
},
"schematics": {
"@nrwl/angular:application": {
"style": "scss",
"linter": "eslint",
"unitTestRunner": "jest",
"e2eTestRunner": "cypress"
"e2eTestRunner": "cypress",
"strict": true
},
"@nrwl/angular:library": {
"style": "scss",
"linter": "eslint",
"unitTestRunner": "jest",
"strict": true
},
"@schematics/angular:component": {
"style": "scss",
"changeDetection": "OnPush",
"prefix": "al"
"prefix": "al",
"viewEncapsulation": "ShadowDom"
},
"@nrwl/angular:component": {
"style": "scss"
}
},
"defaultProject": "todo"
Expand Down
2 changes: 2 additions & 0 deletions apps/favourite-e2e/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/* eslint-env node */
module.exports = require('../../.eslintrc.js');
12 changes: 12 additions & 0 deletions apps/favourite-e2e/cypress.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"fileServerFolder": ".",
"fixturesFolder": "./src/fixtures",
"integrationFolder": "./src/integration",
"modifyObstructiveCode": false,
"pluginsFile": "./src/plugins/index",
"supportFile": "./src/support/index.ts",
"video": true,
"videosFolder": "../../dist/cypress/apps/favourite-e2e/videos",
"screenshotsFolder": "../../dist/cypress/apps/favourite-e2e/screenshots",
"chromeWebSecurity": false
}
4 changes: 4 additions & 0 deletions apps/favourite-e2e/src/fixtures/example.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"name": "Using fixtures to represent data",
"email": "hello@cypress.io"
}
9 changes: 9 additions & 0 deletions apps/favourite-e2e/src/integration/app.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import {getGreeting} from '../support/app.po';

describe('favourite', () => {
beforeEach(() => cy.visit('/'));

it('should display welcome message', () => {
getGreeting().contains('Bookmarks');
});
});
17 changes: 17 additions & 0 deletions apps/favourite-e2e/src/plugins/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/* eslint-env node */

/**
* This function is called when a project is opened or re-opened (e.g. due to
* the project's config changing)
*/

const {preprocessTypescript} = require('@nrwl/cypress/plugins/preprocessor');

/**
* @param on is used to hook into various events Cypress emits
* @param config is the resolved Cypress config
*/
module.exports = (on, config) => {
// Preprocess Typescript file using Nx helper
on('file:preprocessor', preprocessTypescript(config));
};
6 changes: 6 additions & 0 deletions apps/favourite-e2e/src/support/app.po.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/**
* Get the greeting.
*
* @returns h1 element.
*/
export const getGreeting = (): Cypress.Chainable<JQuery<HTMLHeadingElement>> => cy.get('h1', {includeShadowDom: true});
9 changes: 9 additions & 0 deletions apps/favourite-e2e/src/support/commands.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
/**
* This example commands.js shows you how to
* create various custom commands and overwrite
* existing commands.
*
* For more comprehensive examples of custom
* commands please read more here:
* https://on.cypress.io/custom-commands
*/
17 changes: 17 additions & 0 deletions apps/favourite-e2e/src/support/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/**
* This example support/index.js is processed and
* loaded automatically before your test files.
*
* This is a great place to put global configuration and
* behavior that modifies Cypress.
*
* You can change the location of this file or turn off
* automatically serving support files with the
* 'supportFile' configuration option.
*
* You can read more here:
* https://on.cypress.io/configuration
*/

// Import commands.js using ES2015 syntax:
import './commands';
18 changes: 18 additions & 0 deletions apps/favourite-e2e/tsconfig.e2e.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"sourceMap": false,
"outDir": "../../dist/out-tsc",
"allowJs": true,
"types": ["cypress", "node"],
"forceConsistentCasingInFileNames": true,
"strict": true,
"noImplicitReturns": true,
"noFallthroughCasesInSwitch": true
},
"include": ["src/**/*.ts", "src/**/*.js"],
"angularCompilerOptions": {
"strictInjectionParameters": true,
"strictTemplates": true
}
}
10 changes: 10 additions & 0 deletions apps/favourite-e2e/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"extends": "../../tsconfig.base.json",
"files": [],
"include": [],
"references": [
{
"path": "./tsconfig.e2e.json"
}
]
}
17 changes: 17 additions & 0 deletions apps/favourite/.browserslistrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
# For additional information regarding the format and rule options, please see:
# https://github.com/browserslist/browserslist#queries

# For the full list of supported browsers by the Angular framework, please see:
# https://angular.io/guide/browser-support

# You can see what browsers were selected by your queries by running:
# npx browserslist

last 1 Chrome version
last 1 Firefox version
last 2 Edge major versions
last 2 Safari major versions
last 2 iOS major versions
Firefox ESR
not IE 11 # Angular supports IE 11 only as an opt-in. To opt-in, remove the 'not' prefix on this line.
2 changes: 2 additions & 0 deletions apps/favourite/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/* eslint-env node */
module.exports = require('../../.eslintrc.js');
Loading