Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: core updates (ng17) #199

Closed
wants to merge 10 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -76,3 +76,4 @@ apps/extension-toolkit/www_sourcemaps
.next/

.eslintcache
.nx/cache
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@
/coverage
*.geojson.json
.angular

/.nx/cache
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
1. Download and install [Git](https://git-scm.com/downloads)
This will be used to download the repository

2. Download and install [Node](https://nodejs.org/en/download/) version 16+
2. Download and install [Node](https://nodejs.org/en/download/) version 18+
This is the programming lanugage required to run the project

3. Download and Install [Yarn](https://yarnpkg.com/getting-started/install)
Expand Down
2 changes: 1 addition & 1 deletion apps/picsa-apps/content-dashboard-e2e/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
}
},
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": ["apps/picsa-apps/content-dashboard-e2e/**/*.{js,ts}"]
Expand Down
14 changes: 6 additions & 8 deletions apps/picsa-apps/content-dashboard/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"prefix": "picsa",
"targets": {
"build": {
"executor": "@angular-devkit/build-angular:browser",
"executor": "@angular-devkit/build-angular:browser-esbuild",
"outputs": ["{options.outputPath}"],
"options": {
"outputPath": "dist/apps/picsa-apps/content-dashboard",
Expand Down Expand Up @@ -39,7 +39,6 @@
"development": {
"buildOptimizer": false,
"optimization": false,
"vendorChunk": true,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
Expand All @@ -51,22 +50,22 @@
"executor": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"browserTarget": "picsa-apps-content-dashboard:build:production"
"buildTarget": "picsa-apps-content-dashboard:build:production"
},
"development": {
"browserTarget": "picsa-apps-content-dashboard:build:development"
"buildTarget": "picsa-apps-content-dashboard:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"executor": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "picsa-apps-content-dashboard:build"
"buildTarget": "picsa-apps-content-dashboard:build"
}
},
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"options": {
"lintFilePatterns": ["apps/picsa-apps/content-dashboard/**/*.ts", "apps/picsa-apps/content-dashboard/**/*.html"]
}
Expand All @@ -75,8 +74,7 @@
"executor": "@nx/jest:jest",
"outputs": ["{workspaceRoot}/coverage/apps/picsa-apps/content-dashboard"],
"options": {
"jestConfig": "apps/picsa-apps/content-dashboard/jest.config.ts",
"passWithNoTests": true
"jestConfig": "apps/picsa-apps/content-dashboard/jest.config.ts"
}
}
},
Expand Down
2 changes: 1 addition & 1 deletion apps/picsa-apps/extension-app-e2e/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
}
},
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": ["apps/picsa-apps/extension-app-e2e/**/*.{js,ts}"]
Expand Down
4 changes: 2 additions & 2 deletions apps/picsa-apps/extension-app-native/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ android {
applicationId "io.picsa.extension"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 3037003
versionName "3.37.3"
versionCode 3038000
versionName "3.38.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
aaptOptions {
// Files and dirs to omit from the packaged assets dir, modified to accommodate modern web apps.
Expand Down
23 changes: 10 additions & 13 deletions apps/picsa-apps/extension-app/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"save-svg-as-png",
"stacktrace-js"
],
"executor": "@angular-devkit/build-angular:browser",
"executor": "@angular-devkit/build-angular:browser-esbuild",
"outputs": ["{options.outputPath}"],
"options": {
"outputPath": "dist/apps/picsa-apps/extension-app",
Expand Down Expand Up @@ -79,7 +79,6 @@
"input": "apps/picsa-tools/monitoring-tool/src/assets",
"output": "assets"
},

{
"glob": "**/*",
"input": "apps/picsa-tools/option-tool/src/assets",
Expand Down Expand Up @@ -140,7 +139,6 @@
"development": {
"buildOptimizer": false,
"optimization": false,
"vendorChunk": true,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
Expand Down Expand Up @@ -196,30 +194,30 @@
"executor": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"browserTarget": "picsa-apps-extension-app:build:production"
"buildTarget": "picsa-apps-extension-app:build:production"
},
"development": {
"browserTarget": "picsa-apps-extension-app:build:development"
"buildTarget": "picsa-apps-extension-app:build:development"
},
"external": {
"browserTarget": "picsa-apps-extension-app:build:development",
"host": "0.0.0.0"
"host": "0.0.0.0",
"buildTarget": "picsa-apps-extension-app:build:development"
},
"external_production": {
"browserTarget": "picsa-apps-extension-app:build:production",
"host": "0.0.0.0"
"host": "0.0.0.0",
"buildTarget": "picsa-apps-extension-app:build:production"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"executor": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "picsa-apps-extension-app:build"
"buildTarget": "picsa-apps-extension-app:build"
}
},
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"options": {
"lintFilePatterns": ["apps/picsa-apps/extension-app/**/*.ts", "apps/picsa-apps/extension-app/**/*.html"]
}
Expand All @@ -228,8 +226,7 @@
"executor": "@nx/jest:jest",
"outputs": ["{workspaceRoot}/coverage/apps/picsa-apps/extension-app"],
"options": {
"jestConfig": "apps/picsa-apps/extension-app/jest.config.ts",
"passWithNoTests": true
"jestConfig": "apps/picsa-apps/extension-app/jest.config.ts"
}
}
},
Expand Down
12 changes: 5 additions & 7 deletions apps/picsa-apps/extension-app/src/app/pages/home/home.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

<div class="page-content background-image">
<div class="link-grid">
@for (link of links; track $index) {
<div
*ngFor="let link of links"
[attr.data-tour-id]="link.tourId"
[attr.data-dev-only]="link.devOnly"
data-cy="link"
Expand All @@ -16,13 +16,11 @@
<mat-icon [svgIcon]="link.icon" class="nav-icon"></mat-icon>
<div class="nav-text">{{ link.name | translate }}</div>
</div>
<div
class="tile-badge mat-elevation-z8"
*ngIf="link.tourId==='monitoring' && monitoringService.pendingSyncCount>0"
>
{{monitoringService.pendingSyncCount}}
</div>
@if (link.tourId==='monitoring' && monitoringService.pendingSyncCount>0) {
<div class="tile-badge mat-elevation-z8">{{monitoringService.pendingSyncCount}}</div>
}
</div>
}
<div class="grid-tile" (click)="startTour()" style="position: relative">
<div style="text-align: center">
<mat-icon svgIcon="picsa_tutorial" class="nav-icon"></mat-icon>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
<p><strong>Contact Us</strong></p>
<p>
If you have any questions or suggestions about our Privacy Policy, do not hesitate to contact us at
apps@c2dev.co.uk.
apps&#64;c2dev.co.uk.
</p>
<p>
This privacy policy page was created at
Expand Down
2 changes: 1 addition & 1 deletion apps/picsa-apps/extension-app/src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<script
type="text/javascript"
id="compatibility"
src="/assets/compatibility.js"
src="./assets/compatibility.js"
async="false"
defer="false"
></script>
Expand Down
2 changes: 1 addition & 1 deletion apps/picsa-apps/farmer-app-e2e/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
}
},
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": ["apps/picsa-apps/farmer-app-e2e/**/*.{js,ts}"]
Expand Down
14 changes: 6 additions & 8 deletions apps/picsa-apps/farmer-app/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"prefix": "picsa",
"targets": {
"build": {
"executor": "@angular-devkit/build-angular:browser",
"executor": "@angular-devkit/build-angular:browser-esbuild",
"outputs": ["{options.outputPath}"],
"options": {
"outputPath": "dist/apps/picsa-apps/farmer-app",
Expand Down Expand Up @@ -44,7 +44,6 @@
"development": {
"buildOptimizer": false,
"optimization": false,
"vendorChunk": true,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
Expand All @@ -56,22 +55,22 @@
"executor": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"browserTarget": "picsa-apps-farmer-app:build:production"
"buildTarget": "picsa-apps-farmer-app:build:production"
},
"development": {
"browserTarget": "picsa-apps-farmer-app:build:development"
"buildTarget": "picsa-apps-farmer-app:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"executor": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "picsa-apps-farmer-app:build"
"buildTarget": "picsa-apps-farmer-app:build"
}
},
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"options": {
"lintFilePatterns": ["apps/picsa-apps/farmer-app/**/*.ts", "apps/picsa-apps/farmer-app/**/*.html"]
}
Expand All @@ -80,8 +79,7 @@
"executor": "@nx/jest:jest",
"outputs": ["{workspaceRoot}/coverage/apps/picsa-apps/farmer-app"],
"options": {
"jestConfig": "apps/picsa-apps/farmer-app/jest.config.ts",
"passWithNoTests": true
"jestConfig": "apps/picsa-apps/farmer-app/jest.config.ts"
}
}
},
Expand Down
2 changes: 1 addition & 1 deletion apps/picsa-server-legacy/scripts/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"implicitDependencies": ["picsa-server-cloud-functions"],
"targets": {
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": ["apps/picsa-server-legacy/scripts/**/*.ts"]
Expand Down
5 changes: 2 additions & 3 deletions apps/picsa-server-legacy/test/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"implicitDependencies": [],
"targets": {
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": ["apps/picsa-server-legacy/test/**/*.ts"]
Expand All @@ -16,8 +16,7 @@
"executor": "@nx/jest:jest",
"outputs": ["{workspaceRoot}/coverage/apps/picsa-server-legacy/test"],
"options": {
"jestConfig": "apps/picsa-server-legacy/test/jest.config.ts",
"passWithNoTests": true
"jestConfig": "apps/picsa-server-legacy/test/jest.config.ts"
}
}
},
Expand Down
19 changes: 19 additions & 0 deletions apps/picsa-server/TODO.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
**Features**

**Misc**

- Update legacy docs

- Drop additional kobo_sync columns no longer used (not permanent store of kobo metadata)

- Consider calling proxy directly from app (essentially two separate sync protocols)

- Handle submit of forms created on different profile/app language

**Documentation**

- functions KOBO_API_KEY
- Different endpoints (kpi default however can't create submissions and can only bulk edit, so use more kc submissions). E.g. docs https://kf.kobotoolbox.org/api/v2/assets/aLgKwDoHNd38sZyBQMV293/data/ and https://kc.kobotoolbox.org/api/v1/data
Submissions api only for submitting new entries, need to separately use v1 data api or v2 data api to remove data

- Export insomnia workspaces
1 change: 0 additions & 1 deletion apps/picsa-server/_deprecated/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"cwd": "apps/picsa-server/docker"
}
},

"scripts": {
"executor": "nx:run-commands",
"dependsOn": [],
Expand Down
2 changes: 0 additions & 2 deletions apps/picsa-server/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
"cwd": "apps/picsa-server"
}
},

"test-functions": {
"executor": "nx:run-commands",
"dependsOn": [],
Expand All @@ -42,7 +41,6 @@
"cwd": "apps/picsa-server/supabase/functions"
}
},

"gen-types": {
"executor": "nx:run-commands",
"dependsOn": [],
Expand Down
2 changes: 1 addition & 1 deletion apps/picsa-tools/budget-tool-e2e/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
}
},
"lint": {
"executor": "@nx/linter:eslint",
"executor": "@nx/eslint:lint",
"outputs": ["{options.outputFile}"],
"options": {
"lintFilePatterns": ["apps/picsa-tools/budget-tool-e2e/**/*.{js,ts}"]
Expand Down
Loading
Loading