diff --git a/clients/html/angular.json b/clients/html/angular.json index 80f669e..848c482 100755 --- a/clients/html/angular.json +++ b/clients/html/angular.json @@ -20,7 +20,10 @@ "outputPath": "dist/quoting-tool", "index": "src/index.html", "main": "src/main.ts", - "polyfills": ["zone.js", "@angular/localize/init"], + "polyfills": [ + "zone.js", + "@angular/localize/init" + ], "tsConfig": "src/tsconfig.app.json", "assets": [ "src/favicon.ico", @@ -70,20 +73,8 @@ }, "fileReplacements": [ { - "replace": "src/data/zipCode.json", - "with": "src/data/zipCodeME.json" - }, - { - "replace": "src/assets/images/mhc_logo.svg", - "with": "src/assets/images/logo_me.svg" - }, - { - "replace": "src/assets/favicon.png", - "with": "src/assets/favicon_me.png" - }, - { - "replace": "src/assets/roster_upload_template.xlsx", - "with": "src/assets/roster_upload_template_me.xlsx" + "replace": "src/app/brand.config.ts", + "with": "src/app/brand.config.me.ts" } ] }, @@ -114,20 +105,8 @@ "with": "src/environments/environment.prod.ts" }, { - "replace": "src/data/zipCode.json", - "with": "src/data/zipCodeME.json" - }, - { - "replace": "src/assets/images/mhc_logo.svg", - "with": "src/assets/images/logo_me.svg" - }, - { - "replace": "src/assets/favicon.png", - "with": "src/assets/favicon_me.png" - }, - { - "replace": "src/assets/roster_upload_template.xlsx", - "with": "src/assets/roster_upload_template_me.xlsx" + "replace": "src/app/brand.config.ts", + "with": "src/app/brand.config.me.ts" } ], "optimization": true, @@ -152,7 +131,7 @@ }, { "replace": "src/app/brand.config.ts", - "with": "src/app/brand.config.me.ts" + "with": "src/app/brand.config.dc.ts" } ], "optimization": true, @@ -199,7 +178,10 @@ "builder": "@angular-devkit/build-angular:karma", "options": { "main": "src/test.ts", - "polyfills": ["zone.js", "zone.js/testing"], + "polyfills": [ + "zone.js", + "zone.js/testing" + ], "tsConfig": "src/tsconfig.spec.json", "karmaConfig": "src/karma.conf.js", "styles": [ @@ -239,5 +221,5 @@ }, "cli": { "analytics": false - }, -} + } +} \ No newline at end of file diff --git a/clients/html/browserslist b/clients/html/browserslist index e858dd5..27d9120 100755 --- a/clients/html/browserslist +++ b/clients/html/browserslist @@ -1,9 +1,11 @@ -# This file is currently used by autoprefixer to adjust CSS to support the below specified browsers -# For additional information regarding the format and rule options, please see: +# Used by Autoprefixer and the Angular CLI. +# Every `not …` rule must come AFTER at least one positive include (e.g. `> 0.5%` or `defaults`). +# A file that is only `not IE 11` will fail with: +# "Write any browsers query (for instance, `defaults`) before `not IE 11`" # https://github.com/browserslist/browserslist#queries -# For IE 9-11 support, please uncomment the last line of the file and adjust as needed + > 0.5% last 2 versions -Firefox ESR not dead -IE 9-11 +not kaios > 0 +not op_mini all diff --git a/clients/html/package.json b/clients/html/package.json index dc8f22b..8260c54 100755 --- a/clients/html/package.json +++ b/clients/html/package.json @@ -53,7 +53,6 @@ "zone.js": "~0.14.0" }, "devDependencies": { - "@angular-builders/custom-webpack": "21.0.3", "@angular-devkit/build-angular": "^18.0.0", "@angular/cli": "^18.0.0", "@angular/compiler-cli": "^18.0.0", diff --git a/clients/html/scripts/patch-bootstrap.js b/clients/html/scripts/patch-bootstrap.js index 451a953..560d38f 100644 --- a/clients/html/scripts/patch-bootstrap.js +++ b/clients/html/scripts/patch-bootstrap.js @@ -1,9 +1,12 @@ #!/usr/bin/env node /** - * Patches Bootstrap 5's _root.scss to silence Sass color-in-interpolation warnings. - * Bootstrap uses #{$value} where $value can be a named color (teal, blue, etc.), - * which triggers warnings in Dart Sass 1.77+. Changing to #{"" + $value} forces - * string coercion and eliminates the warnings. + * Patches Bootstrap 5's _root.scss for Dart Sass 1.77+. + * + * 1) `#{"" + $color}` — map keys like "blue" / "aqua" are color values; string coercion in + * `--#{$prefix}…#{$color}…` fixes "You probably don't mean to use the color value … in + * interpolation" on the *key* side. + * 2) `#{"" + $value}` — same for *values* in the @each $color, $value loops (only lines that + * still use `: #{$value};` after step 1), without matching across unrelated blocks. */ const fs = require('fs'); const path = require('path'); @@ -16,18 +19,24 @@ if (!fs.existsSync(file)) { } let content = fs.readFileSync(file, 'utf8'); - -// Only patch the $colors and $theme-colors loops (not $grays which uses numeric keys) -// Replace #{$value} with #{"" + $value} only in @each $color, $value loops const original = content; + +content = content.replaceAll('#{$prefix}#{$color}', '#{$prefix}#{"" + $color}'); +content = content.replaceAll('#{$prefix}gray-#{$color}', '#{$prefix}gray-#{"" + $color}'); + +// Only @each lines that build a --var from $color and assign from $value (not to-rgb(), etc.) +content = content.replace( + /(#\{\$prefix\}#\{"" \+ \$color\}(?:-rgb|-text-emphasis|-bg-subtle|-border-subtle)?)\s*:\s*#\{\$value\}\s*;/g, + '$1: #{"" + $value};' +); content = content.replace( - /(@each \$color, \$value in \$(?:colors|theme-colors) \{[\s\S]*?)#\{\$value\}/g, - (match, prefix) => prefix + '#{"" + $value}' + /(#\{\$prefix\}gray-#\{"" \+ \$color\})\s*:\s*#\{\$value\}\s*;/g, + '$1: #{"" + $value};' ); if (content === original) { console.log('Bootstrap _root.scss already patched or pattern not found.'); } else { fs.writeFileSync(file, content); - console.log('Patched bootstrap/scss/_root.scss to silence Sass color interpolation warnings.'); + console.log('Patched bootstrap/scss/_root.scss to silence Sass interpolation warnings.'); } diff --git a/clients/html/src/app/dropdown-treeview-select/dropdown-treeview-select.component.ts b/clients/html/src/app/dropdown-treeview-select/dropdown-treeview-select.component.ts index efb7ef6..40031f9 100644 --- a/clients/html/src/app/dropdown-treeview-select/dropdown-treeview-select.component.ts +++ b/clients/html/src/app/dropdown-treeview-select/dropdown-treeview-select.component.ts @@ -11,6 +11,7 @@ import sicCodes from '../../data/sicCodes.json'; export class DropdownTreeviewSelectComponent implements OnInit { items: TreeviewItem[]; sicCodes = sicCodes; + filterText = ''; config = TreeviewConfig.create({ hasFilter: true, diff --git a/clients/html/src/app/employer-details/employer-details.component.html b/clients/html/src/app/employer-details/employer-details.component.html index 5d3cb36..63bf484 100644 --- a/clients/html/src/app/employer-details/employer-details.component.html +++ b/clients/html/src/app/employer-details/employer-details.component.html @@ -22,7 +22,7 @@

Employer Information

id="inlineFormCustomSelect" formControlName="effectiveDate" id="effectiveDate" - (change)="updateEffectiveDate($event.target.value)" + (change)="onEffectiveDateChange($event)" >