diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 66c1c49e8..a582fd507 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,30 +1,16 @@ version: 2 updates: - - package-ecosystem: npm - directory: '/angular-workspace/' - schedule: - interval: monthly - open-pull-requests-limit: 2 - - - package-ecosystem: npm - directory: '/react-workspace/' - schedule: - interval: monthly - open-pull-requests-limit: 2 - - package-ecosystem: npm directory: '/stencil-workspace/' schedule: interval: monthly versioning-strategy: increase - open-pull-requests-limit: 2 - package-ecosystem: npm directory: '/stencil-workspace/storybook/' schedule: interval: monthly versioning-strategy: increase - open-pull-requests-limit: 2 - package-ecosystem: github-actions directory: '/' diff --git a/.github/workflows/axe-linter.yml b/.github/workflows/axe-linter.yml new file mode 100644 index 000000000..c899cd16b --- /dev/null +++ b/.github/workflows/axe-linter.yml @@ -0,0 +1,14 @@ +name: Linting for accessibility issues + +on: [pull_request] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: dequelabs/axe-linter-action@v1 + with: + api_key: ${{ secrets.AXE_LINTER_API_KEY }} + github_token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/publish-angular.yml b/.github/workflows/publish-angular.yml index e79efa94a..d4a1360f0 100644 --- a/.github/workflows/publish-angular.yml +++ b/.github/workflows/publish-angular.yml @@ -45,6 +45,14 @@ jobs: node-version: '18.x' registry-url: 'https://registry.npmjs.org' + - name: Install Modus Web Components + run: npm ci + working-directory: ./stencil-workspace + + - name: Build Modus Web Components + run: npm run build + working-directory: ./stencil-workspace + - name: npm install run: npm i working-directory: ./angular-workspace/ng${{ github.event.inputs.angularVersion }}/projects/trimble-oss/modus-angular-components diff --git a/.github/workflows/publish-react.yml b/.github/workflows/publish-react.yml index a70c8d28d..9b56f4f71 100644 --- a/.github/workflows/publish-react.yml +++ b/.github/workflows/publish-react.yml @@ -32,6 +32,14 @@ jobs: node-version: '16.x' registry-url: 'https://registry.npmjs.org' + - name: Install Modus Web Components + run: npm ci + working-directory: ./stencil-workspace + + - name: Build Modus Web Components + run: npm run build + working-directory: ./stencil-workspace + - name: Install React ${{ github.event.inputs.reactVersion }} run: npm ci diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml index 110cdb5c2..c469856c7 100644 --- a/.github/workflows/super-linter.yml +++ b/.github/workflows/super-linter.yml @@ -7,7 +7,7 @@ on: branches-ignore: - 'dependabot/**' -permissions: # added using https://github.com/step-security/secure-workflows +permissions: contents: read jobs: @@ -25,7 +25,7 @@ jobs: fetch-depth: 0 - name: Lint Code Base - uses: github/super-linter/slim@v5 + uses: github/super-linter/slim@v6 env: DEFAULT_BRANCH: main GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -36,6 +36,7 @@ jobs: MARKDOWN_CONFIG_FILE: .markdownlint.json SUPPRESS_POSSUM: true VALIDATE_ALL_CODEBASE: false + VALIDATE_CHECKOV: false VALIDATE_CSS: false VALIDATE_EDITORCONFIG: false VALIDATE_GITLEAKS: false diff --git a/.gitignore b/.gitignore index cd5c351ac..0296afedb 100644 --- a/.gitignore +++ b/.gitignore @@ -28,6 +28,8 @@ Thumbs.db UserInterfaceState.xcuserstate .env +**/stencil-generated/** + stencil-workspace/generate-icons/generate-icons.js stencil-workspace/src/icons/generated-icons/*.tsx stencil-workspace/src/icons/ModusIconMap.tsx diff --git a/angular-workspace/ng14/package-lock.json b/angular-workspace/ng14/package-lock.json index aab91ce9d..784a1edea 100644 --- a/angular-workspace/ng14/package-lock.json +++ b/angular-workspace/ng14/package-lock.json @@ -16,7 +16,7 @@ "@angular/platform-browser": "^14.1.1", "@angular/platform-browser-dynamic": "^14.1.1", "@angular/router": "^14.1.1", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.12.0" @@ -3100,9 +3100,9 @@ } }, "node_modules/@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "dependencies": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -5875,17 +5875,17 @@ "dev": true }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -5922,34 +5922,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "node_modules/express/node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/express/node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" @@ -5988,21 +5964,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "node_modules/express/node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/express/node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", diff --git a/angular-workspace/ng14/package.json b/angular-workspace/ng14/package.json index b61bb7783..062ce67df 100644 --- a/angular-workspace/ng14/package.json +++ b/angular-workspace/ng14/package.json @@ -18,7 +18,7 @@ "@angular/platform-browser": "^14.1.1", "@angular/platform-browser-dynamic": "^14.1.1", "@angular/router": "^14.1.1", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.12.0" diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package-lock.json b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package-lock.json index 661737fd2..a863153d5 100644 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package-lock.json +++ b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng14", + "version": "0.27.0-ng14", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng14", + "version": "0.27.0-ng14", "license": "MIT", "dependencies": { "tslib": "^2.5.3" @@ -17,7 +17,7 @@ "peerDependencies": { "@angular/common": "^14.1.1", "@angular/core": "^14.1.1", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" } }, "node_modules/tslib": { diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package.json b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package.json index 1101cb140..d28f45911 100644 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package.json +++ b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/package.json @@ -1,6 +1,6 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng14", + "version": "0.27.0-ng14", "license": "MIT", "description": "Trimble Modus Angular Components Library", "homepage": "https://modus-web-components.trimble.com/", @@ -14,7 +14,7 @@ "peerDependencies": { "@angular/common": "^14.1.1", "@angular/core": "^14.1.1", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "dependencies": { "tslib": "^2.5.3" diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts deleted file mode 100644 index b75904879..000000000 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* eslint-disable */ -/* tslint:disable */ -import { fromEvent } from 'rxjs'; - -export const proxyInputs = (Cmp: any, inputs: string[]) => { - const Prototype = Cmp.prototype; - inputs.forEach((item) => { - Object.defineProperty(Prototype, item, { - get() { - return this.el[item]; - }, - set(val: any) { - this.z.runOutsideAngular(() => (this.el[item] = val)); - }, - /** - * In the event that proxyInputs is called - * multiple times re-defining these inputs - * will cause an error to be thrown. As a result - * we set configurable: true to indicate these - * properties can be changed. - */ - configurable: true, - }); - }); -}; - -export const proxyMethods = (Cmp: any, methods: string[]) => { - const Prototype = Cmp.prototype; - methods.forEach((methodName) => { - Prototype[methodName] = function () { - const args = arguments; - return this.z.runOutsideAngular(() => this.el[methodName].apply(this.el, args)); - }; - }); -}; - -export const proxyOutputs = (instance: any, el: any, events: string[]) => { - events.forEach((eventName) => (instance[eventName] = fromEvent(el, eventName))); -}; - -export const defineCustomElement = (tagName: string, customElement: any) => { - if (customElement !== undefined && typeof customElements !== 'undefined' && !customElements.get(tagName)) { - customElements.define(tagName, customElement); - } -}; - -// tslint:disable-next-line: only-arrow-functions -export function ProxyCmp(opts: { defineCustomElementFn?: () => void; inputs?: any; methods?: any }) { - const decorator = function (cls: any) { - const { defineCustomElementFn, inputs, methods } = opts; - - if (defineCustomElementFn !== undefined) { - defineCustomElementFn(); - } - - if (inputs) { - proxyInputs(cls, inputs); - } - if (methods) { - proxyMethods(cls, methods); - } - return cls; - }; - return decorator; -} diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts deleted file mode 100644 index a51d1d535..000000000 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-checkbox, modus-switch', - host: { - '(checkboxClick)': 'handleChangeEvent($event.target.checked)', - '(switchClick)': 'handleChangeEvent($event.target.checked)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: BooleanValueAccessor, - multi: true - } - ] -}) -export class BooleanValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } - writeValue(value: any) { - this.el.nativeElement.checked = this.lastValue = value == null ? false : value; - } -} diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts deleted file mode 100644 index a2b7be9e2..000000000 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts +++ /dev/null @@ -1,1653 +0,0 @@ -/* tslint:disable */ -/* auto-generated angular directive proxies */ -import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, EventEmitter, NgZone } from '@angular/core'; - -import { ProxyCmp, proxyOutputs } from './angular-component-lib/utils'; - -import { Components } from '@trimble-oss/modus-web-components'; - - -@ProxyCmp({ - inputs: ['ariaLabel'] -}) -@Component({ - selector: 'modus-accordion', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel'], -}) -export class ModusAccordion { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusAccordion extends Components.ModusAccordion {} - - -@ProxyCmp({ - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'] -}) -@Component({ - selector: 'modus-accordion-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'], -}) -export class ModusAccordionItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened']); - } -} - - -export declare interface ModusAccordionItem extends Components.ModusAccordionItem { - /** - * An event that fires on every accordion close. - */ - closed: EventEmitter>; - /** - * An event that fires on every accordion open. - */ - opened: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'size', 'visibleItemCount'] -}) -@Component({ - selector: 'modus-action-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'size', 'visibleItemCount'], -}) -export class ModusActionBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['actionBarClick']); - } -} - - -export declare interface ModusActionBar extends Components.ModusActionBar { - /** - * (optional) An event that fires on action item click. - */ - actionBarClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'] -}) -@Component({ - selector: 'modus-alert', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'], -}) -export class ModusAlert { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick', 'actionClick']); - } -} - - -export declare interface ModusAlert extends Components.ModusAlert { - /** - * An event that fires when the alert is dismissed - */ - dismissClick: EventEmitter>; - /** - * An event that firest when the action button is clicked - */ - actionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'] -}) -@Component({ - selector: 'modus-autocomplete', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'], -}) -export class ModusAutocomplete { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['optionSelected', 'valueChange']); - } -} - - -export declare interface ModusAutocomplete extends Components.ModusAutocomplete { - /** - * An event that fires when a dropdown option is selected. Emits the option id. - */ - optionSelected: EventEmitter>; - /** - * An event that fires when the input value changes. Emits the value string. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'color', 'size', 'type'] -}) -@Component({ - selector: 'modus-badge', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'color', 'size', 'type'], -}) -export class ModusBadge { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusBadge extends Components.ModusBadge {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'] -}) -@Component({ - selector: 'modus-breadcrumb', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'], -}) -export class ModusBreadcrumb { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['crumbClick']); - } -} - - -import type { Crumb as IModusBreadcrumbCrumb } from '@trimble-oss/modus-web-components'; - -export declare interface ModusBreadcrumb extends Components.ModusBreadcrumb { - /** - * (optional) An event that fires on breadcrumb click. - */ - crumbClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], - methods: ['focusButton'] -}) -@Component({ - selector: 'modus-button', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], -}) -export class ModusButton { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusButton extends Components.ModusButton { - /** - * (optional) An event that fires on button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'] -}) -@Component({ - selector: 'modus-card', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'], -}) -export class ModusCard { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusCard extends Components.ModusCard {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], - methods: ['focusCheckbox'] -}) -@Component({ - selector: 'modus-checkbox', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], -}) -export class ModusCheckbox { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick']); - } -} - - -export declare interface ModusCheckbox extends Components.ModusCheckbox { - /** - * An event that fires on checkbox click. - */ - checkboxClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'] -}) -@Component({ - selector: 'modus-chip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'], -}) -export class ModusChip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['chipClick', 'closeClick']); - } -} - - -export declare interface ModusChip extends Components.ModusChip { - /** - * An event that fires on chip click. - */ - chipClick: EventEmitter>; - /** - * An event that fires on close icon click. - */ - closeClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'] -}) -@Component({ - selector: 'modus-data-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'], -}) -export class ModusDataTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellLinkClick', 'rowDoubleClick', 'selection', 'sort', 'rowActionClick']); - } -} - - -import type { ModusDataTableCellLink as IModusDataTableModusDataTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableSortEvent as IModusDataTableModusDataTableSortEvent } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableRowActionClickEvent as IModusDataTableModusDataTableRowActionClickEvent } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDataTable extends Components.ModusDataTable { - /** - * An event that fires on cell link click. - */ - cellLinkClick: EventEmitter>; - /** - * An event that fires on row double click. - */ - rowDoubleClick: EventEmitter>; - /** - * An event that fires on selection change. - */ - selection: EventEmitter>; - /** - * An event that fires on column sort. - */ - sort: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], - methods: ['focusInput', 'validate'] -}) -@Component({ - selector: 'modus-date-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], -}) -export class ModusDateInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['calendarIconClicked', 'dateInputBlur', 'valueChange']); - } -} - - -import type { ModusDateInputEventDetails as IModusDateInputModusDateInputEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDateInput extends Components.ModusDateInput { - /** - * An event that fires on calendar icon click. - */ - calendarIconClicked: EventEmitter>; - /** - * An event that fires on input value out of focus. - */ - dateInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['label'] -}) -@Component({ - selector: 'modus-date-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['label'], -}) -export class ModusDatePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusDatePicker extends Components.ModusDatePicker {} - - -@ProxyCmp({ - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'] -}) -@Component({ - selector: 'modus-dropdown', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'], -}) -export class ModusDropdown { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dropdownClose']); - } -} - - -export declare interface ModusDropdown extends Components.ModusDropdown { - /** - * An event that fires on dropdown close. - */ - dropdownClose: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], - methods: ['addFile', 'getError', 'getFiles', 'removeFile'] -}) -@Component({ - selector: 'modus-file-dropzone', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], -}) -export class ModusFileDropzone { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['files']); - } -} - - -export declare interface ModusFileDropzone extends Components.ModusFileDropzone { - /** - * An event that fires when files have been added or removed, regardless of whether they're valid. - */ - files: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'name', 'size'] -}) -@Component({ - selector: 'modus-icon', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'name', 'size'], -}) -export class ModusIcon { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['iconClick']); - } -} - - -export declare interface ModusIcon extends Components.ModusIcon { - /** - * (optional) The click handler function - */ - iconClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-list', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusList { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusList extends Components.ModusList {} - - -@ProxyCmp({ - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-list-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], -}) -export class ModusListItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemClick']); - } -} - - -export declare interface ModusListItem extends Components.ModusListItem { - /** - * An event that fires on list item click - */ - itemClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'icon', 'type'] -}) -@Component({ - selector: 'modus-message', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'icon', 'type'], -}) -export class ModusMessage { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusMessage extends Components.ModusMessage {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], - methods: ['close', 'open'] -}) -@Component({ - selector: 'modus-modal', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], -}) -export class ModusModal { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened', 'primaryButtonClick', 'secondaryButtonClick']); - } -} - - -export declare interface ModusModal extends Components.ModusModal { - /** - * An event that fires on modal close. - */ - closed: EventEmitter>; - /** - * An event that fires on modal open. - */ - opened: EventEmitter>; - /** - * An event that fires on primary button click. - */ - primaryButtonClick: EventEmitter>; - /** - * An event that fires on secondary button click. - */ - secondaryButtonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], - methods: ['hideMainMenu'] -}) -@Component({ - selector: 'modus-navbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], -}) -export class ModusNavbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appsMenuOpen', 'appsMenuAppOpen', 'buttonClick', 'helpOpen', 'mainMenuClick', 'notificationsMenuOpen', 'productLogoClick', 'profileMenuLinkClick', 'profileMenuOpen', 'profileMenuSignOutClick', 'searchChange', 'searchMenuClick']); - } -} - - -import type { ModusNavbarApp as IModusNavbarModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbar extends Components.ModusNavbar { - /** - * An event that fires when the apps menu opens. - */ - appsMenuOpen: EventEmitter>; - /** - * An event that fires when an apps menu app opens. - */ - appsMenuAppOpen: EventEmitter>; - /** - * An event that fires when a button in the custom button list is clicked. - */ - buttonClick: EventEmitter>; - /** - * An event that fires when the help link opens. - */ - helpOpen: EventEmitter>; - /** - * An event that fires on main menu click. - */ - mainMenuClick: EventEmitter>; - /** - * An event that fires when the notifications menu opens. - */ - notificationsMenuOpen: EventEmitter>; - /** - * An event that fires on product logo click. - */ - productLogoClick: EventEmitter>; - /** - * An event that fires on profile menu link click. - */ - profileMenuLinkClick: EventEmitter>; - /** - * An event that fires when the profile menu opens. - */ - profileMenuOpen: EventEmitter>; - /** - * An event that fires on profile menu sign out click. - */ - profileMenuSignOutClick: EventEmitter>; - /** - * An event that fires on search value change. - */ - searchChange: EventEmitter>; - /** - * An event that fires on search button click. - */ - searchMenuClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'reverse'] -}) -@Component({ - selector: 'modus-navbar-apps-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'reverse'], -}) -export class ModusNavbarAppsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appOpen']); - } -} - - -import type { ModusNavbarApp as IModusNavbarAppsMenuModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbarAppsMenu extends Components.ModusNavbarAppsMenu { - - appOpen: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-button-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarButtonMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarButtonMenu extends Components.ModusNavbarButtonMenu {} - - -@ProxyCmp({ - inputs: ['navbarId'] -}) -@Component({ - selector: 'modus-navbar-main-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['navbarId'], -}) -export class ModusNavbarMainMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarMainMenu extends Components.ModusNavbarMainMenu {} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-notifications-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarNotificationsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarNotificationsMenu extends Components.ModusNavbarNotificationsMenu {} - - -@ProxyCmp({ - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'] -}) -@Component({ - selector: 'modus-navbar-profile-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'], -}) -export class ModusNavbarProfileMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['linkClick', 'signOutClick']); - } -} - - -export declare interface ModusNavbarProfileMenu extends Components.ModusNavbarProfileMenu { - - linkClick: EventEmitter>; - - signOutClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-navbar-search-overlay', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusNavbarSearchOverlay { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['close', 'search']); - } -} - - -export declare interface ModusNavbarSearchOverlay extends Components.ModusNavbarSearchOverlay { - /** - * An event that fires on clicking on close button of search overlay - */ - close: EventEmitter>; - /** - * An event that fires on search value change. - */ - search: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-number-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], -}) -export class ModusNumberInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusNumberInput extends Components.ModusNumberInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'] -}) -@Component({ - selector: 'modus-pagination', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'], -}) -export class ModusPagination { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['pageChange']); - } -} - - -export declare interface ModusPagination extends Components.ModusPagination { - /** - * An event that fires on page change. - */ - pageChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'] -}) -@Component({ - selector: 'modus-progress-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'], -}) -export class ModusProgressBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusProgressBar extends Components.ModusProgressBar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'] -}) -@Component({ - selector: 'modus-radio-group', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'], -}) -export class ModusRadioGroup { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusRadioGroup extends Components.ModusRadioGroup { - /** - * Fires on radio button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-select', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], -}) -export class ModusSelect { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'inputBlur']); - } -} - - -export declare interface ModusSelect extends Components.ModusSelect { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on input blur. - */ - inputBlur: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'type'] -}) -@Component({ - selector: 'modus-sentiment-scale', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'type'], -}) -export class ModusSentimentScale { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sentimentSelection']); - } -} - - -export declare interface ModusSentimentScale extends Components.ModusSentimentScale { - /** - * An event that fires the selected sentiment. - */ - sentimentSelection: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'] -}) -@Component({ - selector: 'modus-side-navigation', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'], -}) -export class ModusSideNavigation { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavExpand']); - } -} - - -export declare interface ModusSideNavigation extends Components.ModusSideNavigation { - /** - * An event that fires on side navigation panel collapse & expand. - */ - sideNavExpand: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-side-navigation-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], -}) -export class ModusSideNavigationItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavItemClicked', 'sideNavItemFocus']); - } -} - - -export declare interface ModusSideNavigationItem extends Components.ModusSideNavigationItem { - /** - * An event that fires when mouse click or `Enter` key press on an item. - */ - sideNavItemClicked: EventEmitter>; - /** - * An event that fires when an item is in focus. - */ - sideNavItemFocus: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'] -}) -@Component({ - selector: 'modus-slider', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'], -}) -export class ModusSlider { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'valueInput']); - } -} - - -export declare interface ModusSlider extends Components.ModusSlider { - /** - * An event that fires on slider value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on slider value input. - */ - valueInput: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'size'] -}) -@Component({ - selector: 'modus-spinner', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'size'], -}) -export class ModusSpinner { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusSpinner extends Components.ModusSpinner {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'] -}) -@Component({ - selector: 'modus-switch', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'], -}) -export class ModusSwitch { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['switchClick']); - } -} - - -export declare interface ModusSwitch extends Components.ModusSwitch { - /** - * An event that fires on switch click. - */ - switchClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], - methods: ['getColumnData', 'toggleColumnVisibility'] -}) -@Component({ - selector: 'modus-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], -}) -export class ModusTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellValueChange', 'cellLinkClick', 'columnOrderChange', 'columnSizingChange', 'columnVisibilityChange', 'rowActionClick', 'rowExpanded', 'rowSelectionChange', 'sortChange', 'paginationChange']); - } -} - - -import type { ModusTableCellValueChange as IModusTableModusTableCellValueChange } from '@trimble-oss/modus-web-components'; -import type { ModusTableCellLink as IModusTableModusTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnOrderState as IModusTableModusTableColumnOrderState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnSizingState as IModusTableModusTableColumnSizingState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnVisibilityState as IModusTableModusTableColumnVisibilityState } from '@trimble-oss/modus-web-components'; -import type { ModusTableRowActionClick as IModusTableModusTableRowActionClick } from '@trimble-oss/modus-web-components'; -import type { ModusTableExpandedState as IModusTableModusTableExpandedState } from '@trimble-oss/modus-web-components'; -import type { ModusTableSortingState as IModusTableModusTableSortingState } from '@trimble-oss/modus-web-components'; -import type { ModusTablePaginationState as IModusTableModusTablePaginationState } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTable extends Components.ModusTable { - /** - * Emits the cell value that was edited - */ - cellValueChange: EventEmitter>; - /** - * Emits the link that was clicked - */ - cellLinkClick: EventEmitter>; - /** - * Emits columns in the updated order - */ - columnOrderChange: EventEmitter>; - /** - * Emits latest column size - */ - columnSizingChange: EventEmitter>; - /** - * Emits visibility state of each column - */ - columnVisibilityChange: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; - /** - * Emits expanded state of the columns - */ - rowExpanded: EventEmitter>; - /** - * Emits rows selected - */ - rowSelectionChange: EventEmitter>; - /** - * Emits column sort order - */ - sortChange: EventEmitter>; - /** - * Emits selected page index and size - */ - paginationChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-editor', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'], -}) -export class ModusTableCellEditor { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellEditor extends Components.ModusTableCellEditor {} - - -@ProxyCmp({ - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-main', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'], -}) -export class ModusTableCellMain { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellMain extends Components.ModusTableCellMain {} - - -@ProxyCmp({ - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'] -}) -@Component({ - selector: 'modus-table-columns-visibility', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'], -}) -export class ModusTableColumnsVisibility { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableColumnsVisibility extends Components.ModusTableColumnsVisibility {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-dropdown-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableDropdownMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableDropdownMenu extends Components.ModusTableDropdownMenu {} - - -@ProxyCmp({ - inputs: ['cellBorderless', 'container', 'summaryRow'] -}) -@Component({ - selector: 'modus-table-filler-column', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cellBorderless', 'container', 'summaryRow'], -}) -export class ModusTableFillerColumn { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableFillerColumn extends Components.ModusTableFillerColumn {} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActions { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['overflowRowActions']); - } -} - - -export declare interface ModusTableRowActions extends Components.ModusTableRowActions { - - overflowRowActions: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions-cell', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActionsCell { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsCell extends Components.ModusTableRowActionsCell {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-row-actions-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableRowActionsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsMenu extends Components.ModusTableRowActionsMenu {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-toolbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableToolbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableToolbar extends Components.ModusTableToolbar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'] -}) -@Component({ - selector: 'modus-tabs', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'], -}) -export class ModusTabs { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['tabChange']); - } -} - - -export declare interface ModusTabs extends Components.ModusTabs { - /** - * An event that fires on tab change. - */ - tabChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-text-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], -}) -export class ModusTextInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusTextInput extends Components.ModusTextInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-time-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], -}) -export class ModusTimePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['timeInputBlur', 'valueChange']); - } -} - - -import type { ModusTimePickerEventDetails as IModusTimePickerModusTimePickerEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTimePicker extends Components.ModusTimePicker { - /** - * An event that fires on input value out of focus. - */ - timeInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'] -}) -@Component({ - selector: 'modus-toast', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'], -}) -export class ModusToast { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick']); - } -} - - -export declare interface ModusToast extends Components.ModusToast { - /** - * An event that fires when the toast is dismissed - */ - dismissClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'position', 'text'] -}) -@Component({ - selector: 'modus-tooltip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'position', 'text'], -}) -export class ModusTooltip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTooltip extends Components.ModusTooltip {} - - -@ProxyCmp({ - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'] -}) -@Component({ - selector: 'modus-tree-view', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'], -}) -export class ModusTreeView { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemActionClick']); - } -} - - -export declare interface ModusTreeView extends Components.ModusTreeView { - /** - * Fired when an action is clicked within any tree item. Includes both the `actionId` and `nodeId` of the action and item, respectively. - */ - itemActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], - methods: ['focusItem', 'focusCheckbox'] -}) -@Component({ - selector: 'modus-tree-view-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], -}) -export class ModusTreeViewItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick', 'itemClick', 'itemExpandToggle', 'actionClick']); - } -} - - -export declare interface ModusTreeViewItem extends Components.ModusTreeViewItem { - /** - * An event that fires on tree item checkbox click - */ - checkboxClick: EventEmitter>; - /** - * An event that fires on tree item click - */ - itemClick: EventEmitter>; - /** - * An event that fires on tree item expand/collapse - */ - itemExpandToggle: EventEmitter>; - /** - * Fired when an action button within the tree item is clicked. Includes the `actionId`. - */ - actionClick: EventEmitter>; -} - - diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts deleted file mode 100644 index b0e106326..000000000 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts +++ /dev/null @@ -1,61 +0,0 @@ - -import * as d from './components'; - -export const DIRECTIVES = [ - d.ModusAccordion, - d.ModusAccordionItem, - d.ModusActionBar, - d.ModusAlert, - d.ModusAutocomplete, - d.ModusBadge, - d.ModusBreadcrumb, - d.ModusButton, - d.ModusCard, - d.ModusCheckbox, - d.ModusChip, - d.ModusDataTable, - d.ModusDateInput, - d.ModusDatePicker, - d.ModusDropdown, - d.ModusFileDropzone, - d.ModusIcon, - d.ModusList, - d.ModusListItem, - d.ModusMessage, - d.ModusModal, - d.ModusNavbar, - d.ModusNavbarAppsMenu, - d.ModusNavbarButtonMenu, - d.ModusNavbarMainMenu, - d.ModusNavbarNotificationsMenu, - d.ModusNavbarProfileMenu, - d.ModusNavbarSearchOverlay, - d.ModusNumberInput, - d.ModusPagination, - d.ModusProgressBar, - d.ModusRadioGroup, - d.ModusSelect, - d.ModusSentimentScale, - d.ModusSideNavigation, - d.ModusSideNavigationItem, - d.ModusSlider, - d.ModusSpinner, - d.ModusSwitch, - d.ModusTable, - d.ModusTableCellEditor, - d.ModusTableCellMain, - d.ModusTableColumnsVisibility, - d.ModusTableDropdownMenu, - d.ModusTableFillerColumn, - d.ModusTableRowActions, - d.ModusTableRowActionsCell, - d.ModusTableRowActionsMenu, - d.ModusTableToolbar, - d.ModusTabs, - d.ModusTextInput, - d.ModusTimePicker, - d.ModusToast, - d.ModusTooltip, - d.ModusTreeView, - d.ModusTreeViewItem -]; diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts deleted file mode 100644 index 5d4a57017..000000000 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-select', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: SelectValueAccessor, - multi: true - } - ] -}) -export class SelectValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts deleted file mode 100644 index f1c229300..000000000 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-autocomplete, modus-number-input, modus-text-input', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: TextValueAccessor, - multi: true - } - ] -}) -export class TextValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts b/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts deleted file mode 100644 index 6bb76a6d3..000000000 --- a/angular-workspace/ng14/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { Directive, ElementRef, HostListener } from '@angular/core'; -import { ControlValueAccessor } from '@angular/forms'; - -@Directive({}) -export class ValueAccessor implements ControlValueAccessor { - - private onChange: (value: any) => void = () => {/**/}; - private onTouched: () => void = () => {/**/}; - protected lastValue: any; - - constructor(protected el: ElementRef) {} - - writeValue(value: any) { - this.el.nativeElement.value = this.lastValue = value == null ? '' : value; - } - - handleChangeEvent(value: any) { - if (value !== this.lastValue) { - this.lastValue = value; - this.onChange(value); - } - } - - @HostListener('focusout') - _handleBlurEvent() { - this.onTouched(); - } - - registerOnChange(fn: (value: any) => void) { - this.onChange = fn; - } - registerOnTouched(fn: () => void) { - this.onTouched = fn; - } - - setDisabledState(isDisabled: boolean) { - this.el.nativeElement.disabled = isDisabled; - } -} diff --git a/angular-workspace/ng15/package-lock.json b/angular-workspace/ng15/package-lock.json index 4982f01eb..e4014b6ee 100644 --- a/angular-workspace/ng15/package-lock.json +++ b/angular-workspace/ng15/package-lock.json @@ -16,7 +16,7 @@ "@angular/platform-browser": "^15.2.9", "@angular/platform-browser-dynamic": "^15.2.9", "@angular/router": "^15.2.9", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.12.0" @@ -3548,9 +3548,9 @@ } }, "node_modules/@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "dependencies": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -5942,17 +5942,17 @@ "dev": true }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -5989,34 +5989,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "node_modules/express/node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/express/node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" @@ -6055,21 +6031,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "node_modules/express/node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/express/node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -14733,8 +14694,7 @@ "version": "15.2.10", "resolved": "https://registry.npmjs.org/@ngtools/webpack/-/webpack-15.2.10.tgz", "integrity": "sha512-ZExB4rKh/Saad31O/Ofd2XvRuILuCNTYs0+qJL697Be2pzeewvzBhE4Xe1Mm7Jg13aWSPeuIdzSGOqCdwxxxFQ==", - "dev": true, - "requires": {} + "dev": true }, "@nodelib/fs.scandir": { "version": "2.1.5", @@ -15055,9 +15015,9 @@ "dev": true }, "@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "requires": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -15516,8 +15476,7 @@ "version": "1.9.0", "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz", "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==", - "dev": true, - "requires": {} + "dev": true }, "adjust-sourcemap-loader": { "version": "4.0.0", @@ -16937,17 +16896,17 @@ "dev": true }, "express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -16981,30 +16940,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - } - }, "cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true }, "debug": { @@ -17037,18 +16976,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - } - }, "statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -17662,8 +17589,7 @@ "version": "5.1.0", "resolved": "https://registry.npmjs.org/icss-utils/-/icss-utils-5.1.0.tgz", "integrity": "sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA==", - "dev": true, - "requires": {} + "dev": true }, "ieee754": { "version": "1.2.1", @@ -18390,8 +18316,7 @@ "version": "1.7.0", "resolved": "https://registry.npmjs.org/karma-jasmine-html-reporter/-/karma-jasmine-html-reporter-1.7.0.tgz", "integrity": "sha512-pzum1TL7j90DTE86eFt48/s12hqwQuiD+e5aXx2Dc9wDEn2LfGq6RoAxEZZjFiN0RDSCOnosEKRZWxbQ+iMpQQ==", - "dev": true, - "requires": {} + "dev": true }, "karma-source-map-support": { "version": "1.4.0", @@ -19919,8 +19844,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/postcss-modules-extract-imports/-/postcss-modules-extract-imports-3.0.0.tgz", "integrity": "sha512-bdHleFnP3kZ4NYDhuGlVK+CMrQ/pqUm8bx/oGL93K6gVwiclvX5x0n76fYMKuIGKzlABOy13zsvqjb0f92TEXw==", - "dev": true, - "requires": {} + "dev": true }, "postcss-modules-local-by-default": { "version": "4.0.3", @@ -21233,8 +21157,7 @@ "version": "3.5.2", "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", - "dev": true, - "requires": {} + "dev": true }, "commander": { "version": "2.20.3", @@ -21688,8 +21611,7 @@ "version": "3.5.2", "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", - "dev": true, - "requires": {} + "dev": true }, "json-schema-traverse": { "version": "0.4.1", @@ -21925,8 +21847,7 @@ "version": "8.11.0", "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", - "dev": true, - "requires": {} + "dev": true }, "xxhashjs": { "version": "0.2.2", diff --git a/angular-workspace/ng15/package.json b/angular-workspace/ng15/package.json index 1215eeaf2..1d16c3cb6 100644 --- a/angular-workspace/ng15/package.json +++ b/angular-workspace/ng15/package.json @@ -18,7 +18,7 @@ "@angular/platform-browser": "^15.2.9", "@angular/platform-browser-dynamic": "^15.2.9", "@angular/router": "^15.2.9", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.12.0" diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package-lock.json b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package-lock.json index d50eda25d..5f21e91b0 100644 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package-lock.json +++ b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng15", + "version": "0.27.0-ng15", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng15", + "version": "0.27.0-ng15", "license": "MIT", "dependencies": { "tslib": "^2.5.3" @@ -17,7 +17,7 @@ "peerDependencies": { "@angular/common": "^15.2.9", "@angular/core": "^15.2.9", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" } }, "node_modules/tslib": { diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package.json b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package.json index 9ad996a6e..f2a277c06 100644 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package.json +++ b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/package.json @@ -1,6 +1,6 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng15", + "version": "0.27.0-ng15", "license": "MIT", "description": "Trimble Modus Angular Components Library", "homepage": "https://modus-web-components.trimble.com/", @@ -14,7 +14,7 @@ "peerDependencies": { "@angular/common": "^15.2.9", "@angular/core": "^15.2.9", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "dependencies": { "tslib": "^2.5.3" diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts deleted file mode 100644 index b75904879..000000000 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* eslint-disable */ -/* tslint:disable */ -import { fromEvent } from 'rxjs'; - -export const proxyInputs = (Cmp: any, inputs: string[]) => { - const Prototype = Cmp.prototype; - inputs.forEach((item) => { - Object.defineProperty(Prototype, item, { - get() { - return this.el[item]; - }, - set(val: any) { - this.z.runOutsideAngular(() => (this.el[item] = val)); - }, - /** - * In the event that proxyInputs is called - * multiple times re-defining these inputs - * will cause an error to be thrown. As a result - * we set configurable: true to indicate these - * properties can be changed. - */ - configurable: true, - }); - }); -}; - -export const proxyMethods = (Cmp: any, methods: string[]) => { - const Prototype = Cmp.prototype; - methods.forEach((methodName) => { - Prototype[methodName] = function () { - const args = arguments; - return this.z.runOutsideAngular(() => this.el[methodName].apply(this.el, args)); - }; - }); -}; - -export const proxyOutputs = (instance: any, el: any, events: string[]) => { - events.forEach((eventName) => (instance[eventName] = fromEvent(el, eventName))); -}; - -export const defineCustomElement = (tagName: string, customElement: any) => { - if (customElement !== undefined && typeof customElements !== 'undefined' && !customElements.get(tagName)) { - customElements.define(tagName, customElement); - } -}; - -// tslint:disable-next-line: only-arrow-functions -export function ProxyCmp(opts: { defineCustomElementFn?: () => void; inputs?: any; methods?: any }) { - const decorator = function (cls: any) { - const { defineCustomElementFn, inputs, methods } = opts; - - if (defineCustomElementFn !== undefined) { - defineCustomElementFn(); - } - - if (inputs) { - proxyInputs(cls, inputs); - } - if (methods) { - proxyMethods(cls, methods); - } - return cls; - }; - return decorator; -} diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts deleted file mode 100644 index a51d1d535..000000000 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-checkbox, modus-switch', - host: { - '(checkboxClick)': 'handleChangeEvent($event.target.checked)', - '(switchClick)': 'handleChangeEvent($event.target.checked)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: BooleanValueAccessor, - multi: true - } - ] -}) -export class BooleanValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } - writeValue(value: any) { - this.el.nativeElement.checked = this.lastValue = value == null ? false : value; - } -} diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts deleted file mode 100644 index a2b7be9e2..000000000 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts +++ /dev/null @@ -1,1653 +0,0 @@ -/* tslint:disable */ -/* auto-generated angular directive proxies */ -import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, EventEmitter, NgZone } from '@angular/core'; - -import { ProxyCmp, proxyOutputs } from './angular-component-lib/utils'; - -import { Components } from '@trimble-oss/modus-web-components'; - - -@ProxyCmp({ - inputs: ['ariaLabel'] -}) -@Component({ - selector: 'modus-accordion', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel'], -}) -export class ModusAccordion { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusAccordion extends Components.ModusAccordion {} - - -@ProxyCmp({ - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'] -}) -@Component({ - selector: 'modus-accordion-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'], -}) -export class ModusAccordionItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened']); - } -} - - -export declare interface ModusAccordionItem extends Components.ModusAccordionItem { - /** - * An event that fires on every accordion close. - */ - closed: EventEmitter>; - /** - * An event that fires on every accordion open. - */ - opened: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'size', 'visibleItemCount'] -}) -@Component({ - selector: 'modus-action-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'size', 'visibleItemCount'], -}) -export class ModusActionBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['actionBarClick']); - } -} - - -export declare interface ModusActionBar extends Components.ModusActionBar { - /** - * (optional) An event that fires on action item click. - */ - actionBarClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'] -}) -@Component({ - selector: 'modus-alert', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'], -}) -export class ModusAlert { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick', 'actionClick']); - } -} - - -export declare interface ModusAlert extends Components.ModusAlert { - /** - * An event that fires when the alert is dismissed - */ - dismissClick: EventEmitter>; - /** - * An event that firest when the action button is clicked - */ - actionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'] -}) -@Component({ - selector: 'modus-autocomplete', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'], -}) -export class ModusAutocomplete { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['optionSelected', 'valueChange']); - } -} - - -export declare interface ModusAutocomplete extends Components.ModusAutocomplete { - /** - * An event that fires when a dropdown option is selected. Emits the option id. - */ - optionSelected: EventEmitter>; - /** - * An event that fires when the input value changes. Emits the value string. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'color', 'size', 'type'] -}) -@Component({ - selector: 'modus-badge', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'color', 'size', 'type'], -}) -export class ModusBadge { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusBadge extends Components.ModusBadge {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'] -}) -@Component({ - selector: 'modus-breadcrumb', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'], -}) -export class ModusBreadcrumb { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['crumbClick']); - } -} - - -import type { Crumb as IModusBreadcrumbCrumb } from '@trimble-oss/modus-web-components'; - -export declare interface ModusBreadcrumb extends Components.ModusBreadcrumb { - /** - * (optional) An event that fires on breadcrumb click. - */ - crumbClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], - methods: ['focusButton'] -}) -@Component({ - selector: 'modus-button', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], -}) -export class ModusButton { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusButton extends Components.ModusButton { - /** - * (optional) An event that fires on button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'] -}) -@Component({ - selector: 'modus-card', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'], -}) -export class ModusCard { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusCard extends Components.ModusCard {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], - methods: ['focusCheckbox'] -}) -@Component({ - selector: 'modus-checkbox', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], -}) -export class ModusCheckbox { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick']); - } -} - - -export declare interface ModusCheckbox extends Components.ModusCheckbox { - /** - * An event that fires on checkbox click. - */ - checkboxClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'] -}) -@Component({ - selector: 'modus-chip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'], -}) -export class ModusChip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['chipClick', 'closeClick']); - } -} - - -export declare interface ModusChip extends Components.ModusChip { - /** - * An event that fires on chip click. - */ - chipClick: EventEmitter>; - /** - * An event that fires on close icon click. - */ - closeClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'] -}) -@Component({ - selector: 'modus-data-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'], -}) -export class ModusDataTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellLinkClick', 'rowDoubleClick', 'selection', 'sort', 'rowActionClick']); - } -} - - -import type { ModusDataTableCellLink as IModusDataTableModusDataTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableSortEvent as IModusDataTableModusDataTableSortEvent } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableRowActionClickEvent as IModusDataTableModusDataTableRowActionClickEvent } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDataTable extends Components.ModusDataTable { - /** - * An event that fires on cell link click. - */ - cellLinkClick: EventEmitter>; - /** - * An event that fires on row double click. - */ - rowDoubleClick: EventEmitter>; - /** - * An event that fires on selection change. - */ - selection: EventEmitter>; - /** - * An event that fires on column sort. - */ - sort: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], - methods: ['focusInput', 'validate'] -}) -@Component({ - selector: 'modus-date-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], -}) -export class ModusDateInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['calendarIconClicked', 'dateInputBlur', 'valueChange']); - } -} - - -import type { ModusDateInputEventDetails as IModusDateInputModusDateInputEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDateInput extends Components.ModusDateInput { - /** - * An event that fires on calendar icon click. - */ - calendarIconClicked: EventEmitter>; - /** - * An event that fires on input value out of focus. - */ - dateInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['label'] -}) -@Component({ - selector: 'modus-date-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['label'], -}) -export class ModusDatePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusDatePicker extends Components.ModusDatePicker {} - - -@ProxyCmp({ - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'] -}) -@Component({ - selector: 'modus-dropdown', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'], -}) -export class ModusDropdown { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dropdownClose']); - } -} - - -export declare interface ModusDropdown extends Components.ModusDropdown { - /** - * An event that fires on dropdown close. - */ - dropdownClose: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], - methods: ['addFile', 'getError', 'getFiles', 'removeFile'] -}) -@Component({ - selector: 'modus-file-dropzone', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], -}) -export class ModusFileDropzone { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['files']); - } -} - - -export declare interface ModusFileDropzone extends Components.ModusFileDropzone { - /** - * An event that fires when files have been added or removed, regardless of whether they're valid. - */ - files: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'name', 'size'] -}) -@Component({ - selector: 'modus-icon', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'name', 'size'], -}) -export class ModusIcon { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['iconClick']); - } -} - - -export declare interface ModusIcon extends Components.ModusIcon { - /** - * (optional) The click handler function - */ - iconClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-list', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusList { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusList extends Components.ModusList {} - - -@ProxyCmp({ - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-list-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], -}) -export class ModusListItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemClick']); - } -} - - -export declare interface ModusListItem extends Components.ModusListItem { - /** - * An event that fires on list item click - */ - itemClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'icon', 'type'] -}) -@Component({ - selector: 'modus-message', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'icon', 'type'], -}) -export class ModusMessage { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusMessage extends Components.ModusMessage {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], - methods: ['close', 'open'] -}) -@Component({ - selector: 'modus-modal', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], -}) -export class ModusModal { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened', 'primaryButtonClick', 'secondaryButtonClick']); - } -} - - -export declare interface ModusModal extends Components.ModusModal { - /** - * An event that fires on modal close. - */ - closed: EventEmitter>; - /** - * An event that fires on modal open. - */ - opened: EventEmitter>; - /** - * An event that fires on primary button click. - */ - primaryButtonClick: EventEmitter>; - /** - * An event that fires on secondary button click. - */ - secondaryButtonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], - methods: ['hideMainMenu'] -}) -@Component({ - selector: 'modus-navbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], -}) -export class ModusNavbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appsMenuOpen', 'appsMenuAppOpen', 'buttonClick', 'helpOpen', 'mainMenuClick', 'notificationsMenuOpen', 'productLogoClick', 'profileMenuLinkClick', 'profileMenuOpen', 'profileMenuSignOutClick', 'searchChange', 'searchMenuClick']); - } -} - - -import type { ModusNavbarApp as IModusNavbarModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbar extends Components.ModusNavbar { - /** - * An event that fires when the apps menu opens. - */ - appsMenuOpen: EventEmitter>; - /** - * An event that fires when an apps menu app opens. - */ - appsMenuAppOpen: EventEmitter>; - /** - * An event that fires when a button in the custom button list is clicked. - */ - buttonClick: EventEmitter>; - /** - * An event that fires when the help link opens. - */ - helpOpen: EventEmitter>; - /** - * An event that fires on main menu click. - */ - mainMenuClick: EventEmitter>; - /** - * An event that fires when the notifications menu opens. - */ - notificationsMenuOpen: EventEmitter>; - /** - * An event that fires on product logo click. - */ - productLogoClick: EventEmitter>; - /** - * An event that fires on profile menu link click. - */ - profileMenuLinkClick: EventEmitter>; - /** - * An event that fires when the profile menu opens. - */ - profileMenuOpen: EventEmitter>; - /** - * An event that fires on profile menu sign out click. - */ - profileMenuSignOutClick: EventEmitter>; - /** - * An event that fires on search value change. - */ - searchChange: EventEmitter>; - /** - * An event that fires on search button click. - */ - searchMenuClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'reverse'] -}) -@Component({ - selector: 'modus-navbar-apps-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'reverse'], -}) -export class ModusNavbarAppsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appOpen']); - } -} - - -import type { ModusNavbarApp as IModusNavbarAppsMenuModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbarAppsMenu extends Components.ModusNavbarAppsMenu { - - appOpen: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-button-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarButtonMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarButtonMenu extends Components.ModusNavbarButtonMenu {} - - -@ProxyCmp({ - inputs: ['navbarId'] -}) -@Component({ - selector: 'modus-navbar-main-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['navbarId'], -}) -export class ModusNavbarMainMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarMainMenu extends Components.ModusNavbarMainMenu {} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-notifications-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarNotificationsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarNotificationsMenu extends Components.ModusNavbarNotificationsMenu {} - - -@ProxyCmp({ - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'] -}) -@Component({ - selector: 'modus-navbar-profile-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'], -}) -export class ModusNavbarProfileMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['linkClick', 'signOutClick']); - } -} - - -export declare interface ModusNavbarProfileMenu extends Components.ModusNavbarProfileMenu { - - linkClick: EventEmitter>; - - signOutClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-navbar-search-overlay', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusNavbarSearchOverlay { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['close', 'search']); - } -} - - -export declare interface ModusNavbarSearchOverlay extends Components.ModusNavbarSearchOverlay { - /** - * An event that fires on clicking on close button of search overlay - */ - close: EventEmitter>; - /** - * An event that fires on search value change. - */ - search: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-number-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], -}) -export class ModusNumberInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusNumberInput extends Components.ModusNumberInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'] -}) -@Component({ - selector: 'modus-pagination', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'], -}) -export class ModusPagination { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['pageChange']); - } -} - - -export declare interface ModusPagination extends Components.ModusPagination { - /** - * An event that fires on page change. - */ - pageChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'] -}) -@Component({ - selector: 'modus-progress-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'], -}) -export class ModusProgressBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusProgressBar extends Components.ModusProgressBar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'] -}) -@Component({ - selector: 'modus-radio-group', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'], -}) -export class ModusRadioGroup { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusRadioGroup extends Components.ModusRadioGroup { - /** - * Fires on radio button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-select', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], -}) -export class ModusSelect { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'inputBlur']); - } -} - - -export declare interface ModusSelect extends Components.ModusSelect { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on input blur. - */ - inputBlur: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'type'] -}) -@Component({ - selector: 'modus-sentiment-scale', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'type'], -}) -export class ModusSentimentScale { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sentimentSelection']); - } -} - - -export declare interface ModusSentimentScale extends Components.ModusSentimentScale { - /** - * An event that fires the selected sentiment. - */ - sentimentSelection: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'] -}) -@Component({ - selector: 'modus-side-navigation', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'], -}) -export class ModusSideNavigation { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavExpand']); - } -} - - -export declare interface ModusSideNavigation extends Components.ModusSideNavigation { - /** - * An event that fires on side navigation panel collapse & expand. - */ - sideNavExpand: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-side-navigation-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], -}) -export class ModusSideNavigationItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavItemClicked', 'sideNavItemFocus']); - } -} - - -export declare interface ModusSideNavigationItem extends Components.ModusSideNavigationItem { - /** - * An event that fires when mouse click or `Enter` key press on an item. - */ - sideNavItemClicked: EventEmitter>; - /** - * An event that fires when an item is in focus. - */ - sideNavItemFocus: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'] -}) -@Component({ - selector: 'modus-slider', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'], -}) -export class ModusSlider { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'valueInput']); - } -} - - -export declare interface ModusSlider extends Components.ModusSlider { - /** - * An event that fires on slider value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on slider value input. - */ - valueInput: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'size'] -}) -@Component({ - selector: 'modus-spinner', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'size'], -}) -export class ModusSpinner { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusSpinner extends Components.ModusSpinner {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'] -}) -@Component({ - selector: 'modus-switch', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'], -}) -export class ModusSwitch { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['switchClick']); - } -} - - -export declare interface ModusSwitch extends Components.ModusSwitch { - /** - * An event that fires on switch click. - */ - switchClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], - methods: ['getColumnData', 'toggleColumnVisibility'] -}) -@Component({ - selector: 'modus-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], -}) -export class ModusTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellValueChange', 'cellLinkClick', 'columnOrderChange', 'columnSizingChange', 'columnVisibilityChange', 'rowActionClick', 'rowExpanded', 'rowSelectionChange', 'sortChange', 'paginationChange']); - } -} - - -import type { ModusTableCellValueChange as IModusTableModusTableCellValueChange } from '@trimble-oss/modus-web-components'; -import type { ModusTableCellLink as IModusTableModusTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnOrderState as IModusTableModusTableColumnOrderState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnSizingState as IModusTableModusTableColumnSizingState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnVisibilityState as IModusTableModusTableColumnVisibilityState } from '@trimble-oss/modus-web-components'; -import type { ModusTableRowActionClick as IModusTableModusTableRowActionClick } from '@trimble-oss/modus-web-components'; -import type { ModusTableExpandedState as IModusTableModusTableExpandedState } from '@trimble-oss/modus-web-components'; -import type { ModusTableSortingState as IModusTableModusTableSortingState } from '@trimble-oss/modus-web-components'; -import type { ModusTablePaginationState as IModusTableModusTablePaginationState } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTable extends Components.ModusTable { - /** - * Emits the cell value that was edited - */ - cellValueChange: EventEmitter>; - /** - * Emits the link that was clicked - */ - cellLinkClick: EventEmitter>; - /** - * Emits columns in the updated order - */ - columnOrderChange: EventEmitter>; - /** - * Emits latest column size - */ - columnSizingChange: EventEmitter>; - /** - * Emits visibility state of each column - */ - columnVisibilityChange: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; - /** - * Emits expanded state of the columns - */ - rowExpanded: EventEmitter>; - /** - * Emits rows selected - */ - rowSelectionChange: EventEmitter>; - /** - * Emits column sort order - */ - sortChange: EventEmitter>; - /** - * Emits selected page index and size - */ - paginationChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-editor', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'], -}) -export class ModusTableCellEditor { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellEditor extends Components.ModusTableCellEditor {} - - -@ProxyCmp({ - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-main', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'], -}) -export class ModusTableCellMain { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellMain extends Components.ModusTableCellMain {} - - -@ProxyCmp({ - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'] -}) -@Component({ - selector: 'modus-table-columns-visibility', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'], -}) -export class ModusTableColumnsVisibility { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableColumnsVisibility extends Components.ModusTableColumnsVisibility {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-dropdown-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableDropdownMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableDropdownMenu extends Components.ModusTableDropdownMenu {} - - -@ProxyCmp({ - inputs: ['cellBorderless', 'container', 'summaryRow'] -}) -@Component({ - selector: 'modus-table-filler-column', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cellBorderless', 'container', 'summaryRow'], -}) -export class ModusTableFillerColumn { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableFillerColumn extends Components.ModusTableFillerColumn {} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActions { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['overflowRowActions']); - } -} - - -export declare interface ModusTableRowActions extends Components.ModusTableRowActions { - - overflowRowActions: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions-cell', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActionsCell { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsCell extends Components.ModusTableRowActionsCell {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-row-actions-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableRowActionsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsMenu extends Components.ModusTableRowActionsMenu {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-toolbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableToolbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableToolbar extends Components.ModusTableToolbar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'] -}) -@Component({ - selector: 'modus-tabs', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'], -}) -export class ModusTabs { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['tabChange']); - } -} - - -export declare interface ModusTabs extends Components.ModusTabs { - /** - * An event that fires on tab change. - */ - tabChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-text-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], -}) -export class ModusTextInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusTextInput extends Components.ModusTextInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-time-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], -}) -export class ModusTimePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['timeInputBlur', 'valueChange']); - } -} - - -import type { ModusTimePickerEventDetails as IModusTimePickerModusTimePickerEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTimePicker extends Components.ModusTimePicker { - /** - * An event that fires on input value out of focus. - */ - timeInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'] -}) -@Component({ - selector: 'modus-toast', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'], -}) -export class ModusToast { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick']); - } -} - - -export declare interface ModusToast extends Components.ModusToast { - /** - * An event that fires when the toast is dismissed - */ - dismissClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'position', 'text'] -}) -@Component({ - selector: 'modus-tooltip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'position', 'text'], -}) -export class ModusTooltip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTooltip extends Components.ModusTooltip {} - - -@ProxyCmp({ - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'] -}) -@Component({ - selector: 'modus-tree-view', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'], -}) -export class ModusTreeView { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemActionClick']); - } -} - - -export declare interface ModusTreeView extends Components.ModusTreeView { - /** - * Fired when an action is clicked within any tree item. Includes both the `actionId` and `nodeId` of the action and item, respectively. - */ - itemActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], - methods: ['focusItem', 'focusCheckbox'] -}) -@Component({ - selector: 'modus-tree-view-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], -}) -export class ModusTreeViewItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick', 'itemClick', 'itemExpandToggle', 'actionClick']); - } -} - - -export declare interface ModusTreeViewItem extends Components.ModusTreeViewItem { - /** - * An event that fires on tree item checkbox click - */ - checkboxClick: EventEmitter>; - /** - * An event that fires on tree item click - */ - itemClick: EventEmitter>; - /** - * An event that fires on tree item expand/collapse - */ - itemExpandToggle: EventEmitter>; - /** - * Fired when an action button within the tree item is clicked. Includes the `actionId`. - */ - actionClick: EventEmitter>; -} - - diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts deleted file mode 100644 index b0e106326..000000000 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts +++ /dev/null @@ -1,61 +0,0 @@ - -import * as d from './components'; - -export const DIRECTIVES = [ - d.ModusAccordion, - d.ModusAccordionItem, - d.ModusActionBar, - d.ModusAlert, - d.ModusAutocomplete, - d.ModusBadge, - d.ModusBreadcrumb, - d.ModusButton, - d.ModusCard, - d.ModusCheckbox, - d.ModusChip, - d.ModusDataTable, - d.ModusDateInput, - d.ModusDatePicker, - d.ModusDropdown, - d.ModusFileDropzone, - d.ModusIcon, - d.ModusList, - d.ModusListItem, - d.ModusMessage, - d.ModusModal, - d.ModusNavbar, - d.ModusNavbarAppsMenu, - d.ModusNavbarButtonMenu, - d.ModusNavbarMainMenu, - d.ModusNavbarNotificationsMenu, - d.ModusNavbarProfileMenu, - d.ModusNavbarSearchOverlay, - d.ModusNumberInput, - d.ModusPagination, - d.ModusProgressBar, - d.ModusRadioGroup, - d.ModusSelect, - d.ModusSentimentScale, - d.ModusSideNavigation, - d.ModusSideNavigationItem, - d.ModusSlider, - d.ModusSpinner, - d.ModusSwitch, - d.ModusTable, - d.ModusTableCellEditor, - d.ModusTableCellMain, - d.ModusTableColumnsVisibility, - d.ModusTableDropdownMenu, - d.ModusTableFillerColumn, - d.ModusTableRowActions, - d.ModusTableRowActionsCell, - d.ModusTableRowActionsMenu, - d.ModusTableToolbar, - d.ModusTabs, - d.ModusTextInput, - d.ModusTimePicker, - d.ModusToast, - d.ModusTooltip, - d.ModusTreeView, - d.ModusTreeViewItem -]; diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts deleted file mode 100644 index 5d4a57017..000000000 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-select', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: SelectValueAccessor, - multi: true - } - ] -}) -export class SelectValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts deleted file mode 100644 index f1c229300..000000000 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-autocomplete, modus-number-input, modus-text-input', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: TextValueAccessor, - multi: true - } - ] -}) -export class TextValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts b/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts deleted file mode 100644 index 6bb76a6d3..000000000 --- a/angular-workspace/ng15/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { Directive, ElementRef, HostListener } from '@angular/core'; -import { ControlValueAccessor } from '@angular/forms'; - -@Directive({}) -export class ValueAccessor implements ControlValueAccessor { - - private onChange: (value: any) => void = () => {/**/}; - private onTouched: () => void = () => {/**/}; - protected lastValue: any; - - constructor(protected el: ElementRef) {} - - writeValue(value: any) { - this.el.nativeElement.value = this.lastValue = value == null ? '' : value; - } - - handleChangeEvent(value: any) { - if (value !== this.lastValue) { - this.lastValue = value; - this.onChange(value); - } - } - - @HostListener('focusout') - _handleBlurEvent() { - this.onTouched(); - } - - registerOnChange(fn: (value: any) => void) { - this.onChange = fn; - } - registerOnTouched(fn: () => void) { - this.onTouched = fn; - } - - setDisabledState(isDisabled: boolean) { - this.el.nativeElement.disabled = isDisabled; - } -} diff --git a/angular-workspace/ng16/package-lock.json b/angular-workspace/ng16/package-lock.json index 6b1f071d2..598371053 100644 --- a/angular-workspace/ng16/package-lock.json +++ b/angular-workspace/ng16/package-lock.json @@ -16,7 +16,7 @@ "@angular/platform-browser": "^16.1.7", "@angular/platform-browser-dynamic": "^16.1.7", "@angular/router": "^16.1.7", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.13.1" @@ -2984,9 +2984,9 @@ } }, "node_modules/@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "dependencies": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -5332,17 +5332,17 @@ "dev": true }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -5379,34 +5379,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "node_modules/express/node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/express/node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" @@ -5445,21 +5421,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "node_modules/express/node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/express/node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -11675,8 +11636,7 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/@vitejs/plugin-basic-ssl/-/plugin-basic-ssl-1.0.1.tgz", "integrity": "sha512-pcub+YbFtFhaGRTo1832FQHQSHvMrlb43974e2eS8EKleR3p1cDdkJFPci1UhwkEf1J9Bz+wKBSzqpKp7nNj2A==", - "dev": true, - "requires": {} + "dev": true }, "fast-glob": { "version": "3.2.12", @@ -12273,8 +12233,7 @@ "version": "7.21.0-placeholder-for-preset-env.2", "resolved": "https://registry.npmjs.org/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.21.0-placeholder-for-preset-env.2.tgz", "integrity": "sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w==", - "dev": true, - "requires": {} + "dev": true }, "@babel/plugin-proposal-unicode-property-regex": { "version": "7.18.6", @@ -13323,8 +13282,7 @@ "version": "16.1.6", "resolved": "https://registry.npmjs.org/@ngtools/webpack/-/webpack-16.1.6.tgz", "integrity": "sha512-rDE1bV3+Ys/VyeD6l7JKtbs3+bTQAfWhi7meEuq5mkaJHOERu6Z40ce866faAIX2I1AVpsSv8rLlb7kB7t7kzw==", - "dev": true, - "requires": {} + "dev": true }, "@nodelib/fs.scandir": { "version": "2.1.5", @@ -13559,9 +13517,9 @@ "dev": true }, "@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "requires": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -13997,8 +13955,7 @@ "version": "1.9.0", "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz", "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==", - "dev": true, - "requires": {} + "dev": true }, "adjust-sourcemap-loader": { "version": "4.0.0", @@ -15409,17 +15366,17 @@ "dev": true }, "express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -15453,30 +15410,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - } - }, "cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true }, "debug": { @@ -15509,18 +15446,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - } - }, "statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -16113,8 +16038,7 @@ "version": "5.1.0", "resolved": "https://registry.npmjs.org/icss-utils/-/icss-utils-5.1.0.tgz", "integrity": "sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA==", - "dev": true, - "requires": {} + "dev": true }, "ieee754": { "version": "1.2.1", @@ -16830,8 +16754,7 @@ "version": "1.7.0", "resolved": "https://registry.npmjs.org/karma-jasmine-html-reporter/-/karma-jasmine-html-reporter-1.7.0.tgz", "integrity": "sha512-pzum1TL7j90DTE86eFt48/s12hqwQuiD+e5aXx2Dc9wDEn2LfGq6RoAxEZZjFiN0RDSCOnosEKRZWxbQ+iMpQQ==", - "dev": true, - "requires": {} + "dev": true }, "karma-source-map-support": { "version": "1.4.0", @@ -18150,8 +18073,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/postcss-modules-extract-imports/-/postcss-modules-extract-imports-3.0.0.tgz", "integrity": "sha512-bdHleFnP3kZ4NYDhuGlVK+CMrQ/pqUm8bx/oGL93K6gVwiclvX5x0n76fYMKuIGKzlABOy13zsvqjb0f92TEXw==", - "dev": true, - "requires": {} + "dev": true }, "postcss-modules-local-by-default": { "version": "4.0.3", @@ -19357,8 +19279,7 @@ "version": "3.5.2", "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", - "dev": true, - "requires": {} + "dev": true }, "commander": { "version": "2.20.3", @@ -19755,8 +19676,7 @@ "version": "3.5.2", "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.2.tgz", "integrity": "sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ==", - "dev": true, - "requires": {} + "dev": true }, "json-schema-traverse": { "version": "0.4.1", @@ -19845,8 +19765,7 @@ "version": "8.13.0", "resolved": "https://registry.npmjs.org/ws/-/ws-8.13.0.tgz", "integrity": "sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA==", - "dev": true, - "requires": {} + "dev": true } } }, @@ -20000,8 +19919,7 @@ "version": "8.11.0", "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", - "dev": true, - "requires": {} + "dev": true }, "xxhashjs": { "version": "0.2.2", diff --git a/angular-workspace/ng16/package.json b/angular-workspace/ng16/package.json index 668bcecee..e0f6ffdc9 100644 --- a/angular-workspace/ng16/package.json +++ b/angular-workspace/ng16/package.json @@ -18,7 +18,7 @@ "@angular/platform-browser": "^16.1.7", "@angular/platform-browser-dynamic": "^16.1.7", "@angular/router": "^16.1.7", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.13.1" diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package-lock.json b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package-lock.json index 900873e4f..4c602bea3 100644 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package-lock.json +++ b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng16", + "version": "0.27.0-ng16", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng16", + "version": "0.27.0-ng16", "license": "MIT", "dependencies": { "tslib": "^2.5.3" @@ -17,7 +17,7 @@ "peerDependencies": { "@angular/common": "^16.1.7", "@angular/core": "^16.1.7", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" } }, "node_modules/tslib": { diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package.json b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package.json index 48570c7aa..846ef807a 100644 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package.json +++ b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/package.json @@ -1,6 +1,6 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng16", + "version": "0.27.0-ng16", "license": "MIT", "description": "Trimble Modus Angular Components Library", "homepage": "https://modus-web-components.trimble.com/", @@ -14,7 +14,7 @@ "peerDependencies": { "@angular/common": "^16.1.7", "@angular/core": "^16.1.7", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "dependencies": { "tslib": "^2.5.3" diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts deleted file mode 100644 index b75904879..000000000 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* eslint-disable */ -/* tslint:disable */ -import { fromEvent } from 'rxjs'; - -export const proxyInputs = (Cmp: any, inputs: string[]) => { - const Prototype = Cmp.prototype; - inputs.forEach((item) => { - Object.defineProperty(Prototype, item, { - get() { - return this.el[item]; - }, - set(val: any) { - this.z.runOutsideAngular(() => (this.el[item] = val)); - }, - /** - * In the event that proxyInputs is called - * multiple times re-defining these inputs - * will cause an error to be thrown. As a result - * we set configurable: true to indicate these - * properties can be changed. - */ - configurable: true, - }); - }); -}; - -export const proxyMethods = (Cmp: any, methods: string[]) => { - const Prototype = Cmp.prototype; - methods.forEach((methodName) => { - Prototype[methodName] = function () { - const args = arguments; - return this.z.runOutsideAngular(() => this.el[methodName].apply(this.el, args)); - }; - }); -}; - -export const proxyOutputs = (instance: any, el: any, events: string[]) => { - events.forEach((eventName) => (instance[eventName] = fromEvent(el, eventName))); -}; - -export const defineCustomElement = (tagName: string, customElement: any) => { - if (customElement !== undefined && typeof customElements !== 'undefined' && !customElements.get(tagName)) { - customElements.define(tagName, customElement); - } -}; - -// tslint:disable-next-line: only-arrow-functions -export function ProxyCmp(opts: { defineCustomElementFn?: () => void; inputs?: any; methods?: any }) { - const decorator = function (cls: any) { - const { defineCustomElementFn, inputs, methods } = opts; - - if (defineCustomElementFn !== undefined) { - defineCustomElementFn(); - } - - if (inputs) { - proxyInputs(cls, inputs); - } - if (methods) { - proxyMethods(cls, methods); - } - return cls; - }; - return decorator; -} diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts deleted file mode 100644 index a51d1d535..000000000 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-checkbox, modus-switch', - host: { - '(checkboxClick)': 'handleChangeEvent($event.target.checked)', - '(switchClick)': 'handleChangeEvent($event.target.checked)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: BooleanValueAccessor, - multi: true - } - ] -}) -export class BooleanValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } - writeValue(value: any) { - this.el.nativeElement.checked = this.lastValue = value == null ? false : value; - } -} diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts deleted file mode 100644 index a2b7be9e2..000000000 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts +++ /dev/null @@ -1,1653 +0,0 @@ -/* tslint:disable */ -/* auto-generated angular directive proxies */ -import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, EventEmitter, NgZone } from '@angular/core'; - -import { ProxyCmp, proxyOutputs } from './angular-component-lib/utils'; - -import { Components } from '@trimble-oss/modus-web-components'; - - -@ProxyCmp({ - inputs: ['ariaLabel'] -}) -@Component({ - selector: 'modus-accordion', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel'], -}) -export class ModusAccordion { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusAccordion extends Components.ModusAccordion {} - - -@ProxyCmp({ - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'] -}) -@Component({ - selector: 'modus-accordion-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'], -}) -export class ModusAccordionItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened']); - } -} - - -export declare interface ModusAccordionItem extends Components.ModusAccordionItem { - /** - * An event that fires on every accordion close. - */ - closed: EventEmitter>; - /** - * An event that fires on every accordion open. - */ - opened: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'size', 'visibleItemCount'] -}) -@Component({ - selector: 'modus-action-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'size', 'visibleItemCount'], -}) -export class ModusActionBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['actionBarClick']); - } -} - - -export declare interface ModusActionBar extends Components.ModusActionBar { - /** - * (optional) An event that fires on action item click. - */ - actionBarClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'] -}) -@Component({ - selector: 'modus-alert', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'], -}) -export class ModusAlert { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick', 'actionClick']); - } -} - - -export declare interface ModusAlert extends Components.ModusAlert { - /** - * An event that fires when the alert is dismissed - */ - dismissClick: EventEmitter>; - /** - * An event that firest when the action button is clicked - */ - actionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'] -}) -@Component({ - selector: 'modus-autocomplete', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'], -}) -export class ModusAutocomplete { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['optionSelected', 'valueChange']); - } -} - - -export declare interface ModusAutocomplete extends Components.ModusAutocomplete { - /** - * An event that fires when a dropdown option is selected. Emits the option id. - */ - optionSelected: EventEmitter>; - /** - * An event that fires when the input value changes. Emits the value string. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'color', 'size', 'type'] -}) -@Component({ - selector: 'modus-badge', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'color', 'size', 'type'], -}) -export class ModusBadge { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusBadge extends Components.ModusBadge {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'] -}) -@Component({ - selector: 'modus-breadcrumb', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'], -}) -export class ModusBreadcrumb { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['crumbClick']); - } -} - - -import type { Crumb as IModusBreadcrumbCrumb } from '@trimble-oss/modus-web-components'; - -export declare interface ModusBreadcrumb extends Components.ModusBreadcrumb { - /** - * (optional) An event that fires on breadcrumb click. - */ - crumbClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], - methods: ['focusButton'] -}) -@Component({ - selector: 'modus-button', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], -}) -export class ModusButton { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusButton extends Components.ModusButton { - /** - * (optional) An event that fires on button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'] -}) -@Component({ - selector: 'modus-card', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'], -}) -export class ModusCard { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusCard extends Components.ModusCard {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], - methods: ['focusCheckbox'] -}) -@Component({ - selector: 'modus-checkbox', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], -}) -export class ModusCheckbox { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick']); - } -} - - -export declare interface ModusCheckbox extends Components.ModusCheckbox { - /** - * An event that fires on checkbox click. - */ - checkboxClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'] -}) -@Component({ - selector: 'modus-chip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'], -}) -export class ModusChip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['chipClick', 'closeClick']); - } -} - - -export declare interface ModusChip extends Components.ModusChip { - /** - * An event that fires on chip click. - */ - chipClick: EventEmitter>; - /** - * An event that fires on close icon click. - */ - closeClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'] -}) -@Component({ - selector: 'modus-data-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'], -}) -export class ModusDataTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellLinkClick', 'rowDoubleClick', 'selection', 'sort', 'rowActionClick']); - } -} - - -import type { ModusDataTableCellLink as IModusDataTableModusDataTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableSortEvent as IModusDataTableModusDataTableSortEvent } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableRowActionClickEvent as IModusDataTableModusDataTableRowActionClickEvent } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDataTable extends Components.ModusDataTable { - /** - * An event that fires on cell link click. - */ - cellLinkClick: EventEmitter>; - /** - * An event that fires on row double click. - */ - rowDoubleClick: EventEmitter>; - /** - * An event that fires on selection change. - */ - selection: EventEmitter>; - /** - * An event that fires on column sort. - */ - sort: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], - methods: ['focusInput', 'validate'] -}) -@Component({ - selector: 'modus-date-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], -}) -export class ModusDateInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['calendarIconClicked', 'dateInputBlur', 'valueChange']); - } -} - - -import type { ModusDateInputEventDetails as IModusDateInputModusDateInputEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDateInput extends Components.ModusDateInput { - /** - * An event that fires on calendar icon click. - */ - calendarIconClicked: EventEmitter>; - /** - * An event that fires on input value out of focus. - */ - dateInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['label'] -}) -@Component({ - selector: 'modus-date-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['label'], -}) -export class ModusDatePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusDatePicker extends Components.ModusDatePicker {} - - -@ProxyCmp({ - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'] -}) -@Component({ - selector: 'modus-dropdown', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'], -}) -export class ModusDropdown { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dropdownClose']); - } -} - - -export declare interface ModusDropdown extends Components.ModusDropdown { - /** - * An event that fires on dropdown close. - */ - dropdownClose: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], - methods: ['addFile', 'getError', 'getFiles', 'removeFile'] -}) -@Component({ - selector: 'modus-file-dropzone', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], -}) -export class ModusFileDropzone { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['files']); - } -} - - -export declare interface ModusFileDropzone extends Components.ModusFileDropzone { - /** - * An event that fires when files have been added or removed, regardless of whether they're valid. - */ - files: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'name', 'size'] -}) -@Component({ - selector: 'modus-icon', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'name', 'size'], -}) -export class ModusIcon { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['iconClick']); - } -} - - -export declare interface ModusIcon extends Components.ModusIcon { - /** - * (optional) The click handler function - */ - iconClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-list', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusList { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusList extends Components.ModusList {} - - -@ProxyCmp({ - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-list-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], -}) -export class ModusListItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemClick']); - } -} - - -export declare interface ModusListItem extends Components.ModusListItem { - /** - * An event that fires on list item click - */ - itemClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'icon', 'type'] -}) -@Component({ - selector: 'modus-message', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'icon', 'type'], -}) -export class ModusMessage { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusMessage extends Components.ModusMessage {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], - methods: ['close', 'open'] -}) -@Component({ - selector: 'modus-modal', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], -}) -export class ModusModal { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened', 'primaryButtonClick', 'secondaryButtonClick']); - } -} - - -export declare interface ModusModal extends Components.ModusModal { - /** - * An event that fires on modal close. - */ - closed: EventEmitter>; - /** - * An event that fires on modal open. - */ - opened: EventEmitter>; - /** - * An event that fires on primary button click. - */ - primaryButtonClick: EventEmitter>; - /** - * An event that fires on secondary button click. - */ - secondaryButtonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], - methods: ['hideMainMenu'] -}) -@Component({ - selector: 'modus-navbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], -}) -export class ModusNavbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appsMenuOpen', 'appsMenuAppOpen', 'buttonClick', 'helpOpen', 'mainMenuClick', 'notificationsMenuOpen', 'productLogoClick', 'profileMenuLinkClick', 'profileMenuOpen', 'profileMenuSignOutClick', 'searchChange', 'searchMenuClick']); - } -} - - -import type { ModusNavbarApp as IModusNavbarModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbar extends Components.ModusNavbar { - /** - * An event that fires when the apps menu opens. - */ - appsMenuOpen: EventEmitter>; - /** - * An event that fires when an apps menu app opens. - */ - appsMenuAppOpen: EventEmitter>; - /** - * An event that fires when a button in the custom button list is clicked. - */ - buttonClick: EventEmitter>; - /** - * An event that fires when the help link opens. - */ - helpOpen: EventEmitter>; - /** - * An event that fires on main menu click. - */ - mainMenuClick: EventEmitter>; - /** - * An event that fires when the notifications menu opens. - */ - notificationsMenuOpen: EventEmitter>; - /** - * An event that fires on product logo click. - */ - productLogoClick: EventEmitter>; - /** - * An event that fires on profile menu link click. - */ - profileMenuLinkClick: EventEmitter>; - /** - * An event that fires when the profile menu opens. - */ - profileMenuOpen: EventEmitter>; - /** - * An event that fires on profile menu sign out click. - */ - profileMenuSignOutClick: EventEmitter>; - /** - * An event that fires on search value change. - */ - searchChange: EventEmitter>; - /** - * An event that fires on search button click. - */ - searchMenuClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'reverse'] -}) -@Component({ - selector: 'modus-navbar-apps-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'reverse'], -}) -export class ModusNavbarAppsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appOpen']); - } -} - - -import type { ModusNavbarApp as IModusNavbarAppsMenuModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbarAppsMenu extends Components.ModusNavbarAppsMenu { - - appOpen: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-button-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarButtonMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarButtonMenu extends Components.ModusNavbarButtonMenu {} - - -@ProxyCmp({ - inputs: ['navbarId'] -}) -@Component({ - selector: 'modus-navbar-main-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['navbarId'], -}) -export class ModusNavbarMainMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarMainMenu extends Components.ModusNavbarMainMenu {} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-notifications-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarNotificationsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarNotificationsMenu extends Components.ModusNavbarNotificationsMenu {} - - -@ProxyCmp({ - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'] -}) -@Component({ - selector: 'modus-navbar-profile-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'], -}) -export class ModusNavbarProfileMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['linkClick', 'signOutClick']); - } -} - - -export declare interface ModusNavbarProfileMenu extends Components.ModusNavbarProfileMenu { - - linkClick: EventEmitter>; - - signOutClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-navbar-search-overlay', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusNavbarSearchOverlay { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['close', 'search']); - } -} - - -export declare interface ModusNavbarSearchOverlay extends Components.ModusNavbarSearchOverlay { - /** - * An event that fires on clicking on close button of search overlay - */ - close: EventEmitter>; - /** - * An event that fires on search value change. - */ - search: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-number-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], -}) -export class ModusNumberInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusNumberInput extends Components.ModusNumberInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'] -}) -@Component({ - selector: 'modus-pagination', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'], -}) -export class ModusPagination { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['pageChange']); - } -} - - -export declare interface ModusPagination extends Components.ModusPagination { - /** - * An event that fires on page change. - */ - pageChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'] -}) -@Component({ - selector: 'modus-progress-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'], -}) -export class ModusProgressBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusProgressBar extends Components.ModusProgressBar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'] -}) -@Component({ - selector: 'modus-radio-group', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'], -}) -export class ModusRadioGroup { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusRadioGroup extends Components.ModusRadioGroup { - /** - * Fires on radio button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-select', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], -}) -export class ModusSelect { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'inputBlur']); - } -} - - -export declare interface ModusSelect extends Components.ModusSelect { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on input blur. - */ - inputBlur: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'type'] -}) -@Component({ - selector: 'modus-sentiment-scale', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'type'], -}) -export class ModusSentimentScale { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sentimentSelection']); - } -} - - -export declare interface ModusSentimentScale extends Components.ModusSentimentScale { - /** - * An event that fires the selected sentiment. - */ - sentimentSelection: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'] -}) -@Component({ - selector: 'modus-side-navigation', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'], -}) -export class ModusSideNavigation { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavExpand']); - } -} - - -export declare interface ModusSideNavigation extends Components.ModusSideNavigation { - /** - * An event that fires on side navigation panel collapse & expand. - */ - sideNavExpand: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-side-navigation-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], -}) -export class ModusSideNavigationItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavItemClicked', 'sideNavItemFocus']); - } -} - - -export declare interface ModusSideNavigationItem extends Components.ModusSideNavigationItem { - /** - * An event that fires when mouse click or `Enter` key press on an item. - */ - sideNavItemClicked: EventEmitter>; - /** - * An event that fires when an item is in focus. - */ - sideNavItemFocus: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'] -}) -@Component({ - selector: 'modus-slider', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'], -}) -export class ModusSlider { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'valueInput']); - } -} - - -export declare interface ModusSlider extends Components.ModusSlider { - /** - * An event that fires on slider value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on slider value input. - */ - valueInput: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'size'] -}) -@Component({ - selector: 'modus-spinner', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'size'], -}) -export class ModusSpinner { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusSpinner extends Components.ModusSpinner {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'] -}) -@Component({ - selector: 'modus-switch', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'], -}) -export class ModusSwitch { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['switchClick']); - } -} - - -export declare interface ModusSwitch extends Components.ModusSwitch { - /** - * An event that fires on switch click. - */ - switchClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], - methods: ['getColumnData', 'toggleColumnVisibility'] -}) -@Component({ - selector: 'modus-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], -}) -export class ModusTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellValueChange', 'cellLinkClick', 'columnOrderChange', 'columnSizingChange', 'columnVisibilityChange', 'rowActionClick', 'rowExpanded', 'rowSelectionChange', 'sortChange', 'paginationChange']); - } -} - - -import type { ModusTableCellValueChange as IModusTableModusTableCellValueChange } from '@trimble-oss/modus-web-components'; -import type { ModusTableCellLink as IModusTableModusTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnOrderState as IModusTableModusTableColumnOrderState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnSizingState as IModusTableModusTableColumnSizingState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnVisibilityState as IModusTableModusTableColumnVisibilityState } from '@trimble-oss/modus-web-components'; -import type { ModusTableRowActionClick as IModusTableModusTableRowActionClick } from '@trimble-oss/modus-web-components'; -import type { ModusTableExpandedState as IModusTableModusTableExpandedState } from '@trimble-oss/modus-web-components'; -import type { ModusTableSortingState as IModusTableModusTableSortingState } from '@trimble-oss/modus-web-components'; -import type { ModusTablePaginationState as IModusTableModusTablePaginationState } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTable extends Components.ModusTable { - /** - * Emits the cell value that was edited - */ - cellValueChange: EventEmitter>; - /** - * Emits the link that was clicked - */ - cellLinkClick: EventEmitter>; - /** - * Emits columns in the updated order - */ - columnOrderChange: EventEmitter>; - /** - * Emits latest column size - */ - columnSizingChange: EventEmitter>; - /** - * Emits visibility state of each column - */ - columnVisibilityChange: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; - /** - * Emits expanded state of the columns - */ - rowExpanded: EventEmitter>; - /** - * Emits rows selected - */ - rowSelectionChange: EventEmitter>; - /** - * Emits column sort order - */ - sortChange: EventEmitter>; - /** - * Emits selected page index and size - */ - paginationChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-editor', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'], -}) -export class ModusTableCellEditor { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellEditor extends Components.ModusTableCellEditor {} - - -@ProxyCmp({ - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-main', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'], -}) -export class ModusTableCellMain { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellMain extends Components.ModusTableCellMain {} - - -@ProxyCmp({ - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'] -}) -@Component({ - selector: 'modus-table-columns-visibility', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'], -}) -export class ModusTableColumnsVisibility { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableColumnsVisibility extends Components.ModusTableColumnsVisibility {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-dropdown-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableDropdownMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableDropdownMenu extends Components.ModusTableDropdownMenu {} - - -@ProxyCmp({ - inputs: ['cellBorderless', 'container', 'summaryRow'] -}) -@Component({ - selector: 'modus-table-filler-column', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cellBorderless', 'container', 'summaryRow'], -}) -export class ModusTableFillerColumn { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableFillerColumn extends Components.ModusTableFillerColumn {} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActions { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['overflowRowActions']); - } -} - - -export declare interface ModusTableRowActions extends Components.ModusTableRowActions { - - overflowRowActions: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions-cell', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActionsCell { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsCell extends Components.ModusTableRowActionsCell {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-row-actions-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableRowActionsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsMenu extends Components.ModusTableRowActionsMenu {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-toolbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableToolbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableToolbar extends Components.ModusTableToolbar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'] -}) -@Component({ - selector: 'modus-tabs', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'], -}) -export class ModusTabs { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['tabChange']); - } -} - - -export declare interface ModusTabs extends Components.ModusTabs { - /** - * An event that fires on tab change. - */ - tabChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-text-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], -}) -export class ModusTextInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusTextInput extends Components.ModusTextInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-time-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], -}) -export class ModusTimePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['timeInputBlur', 'valueChange']); - } -} - - -import type { ModusTimePickerEventDetails as IModusTimePickerModusTimePickerEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTimePicker extends Components.ModusTimePicker { - /** - * An event that fires on input value out of focus. - */ - timeInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'] -}) -@Component({ - selector: 'modus-toast', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'], -}) -export class ModusToast { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick']); - } -} - - -export declare interface ModusToast extends Components.ModusToast { - /** - * An event that fires when the toast is dismissed - */ - dismissClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'position', 'text'] -}) -@Component({ - selector: 'modus-tooltip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'position', 'text'], -}) -export class ModusTooltip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTooltip extends Components.ModusTooltip {} - - -@ProxyCmp({ - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'] -}) -@Component({ - selector: 'modus-tree-view', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'], -}) -export class ModusTreeView { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemActionClick']); - } -} - - -export declare interface ModusTreeView extends Components.ModusTreeView { - /** - * Fired when an action is clicked within any tree item. Includes both the `actionId` and `nodeId` of the action and item, respectively. - */ - itemActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], - methods: ['focusItem', 'focusCheckbox'] -}) -@Component({ - selector: 'modus-tree-view-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], -}) -export class ModusTreeViewItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick', 'itemClick', 'itemExpandToggle', 'actionClick']); - } -} - - -export declare interface ModusTreeViewItem extends Components.ModusTreeViewItem { - /** - * An event that fires on tree item checkbox click - */ - checkboxClick: EventEmitter>; - /** - * An event that fires on tree item click - */ - itemClick: EventEmitter>; - /** - * An event that fires on tree item expand/collapse - */ - itemExpandToggle: EventEmitter>; - /** - * Fired when an action button within the tree item is clicked. Includes the `actionId`. - */ - actionClick: EventEmitter>; -} - - diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts deleted file mode 100644 index b0e106326..000000000 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts +++ /dev/null @@ -1,61 +0,0 @@ - -import * as d from './components'; - -export const DIRECTIVES = [ - d.ModusAccordion, - d.ModusAccordionItem, - d.ModusActionBar, - d.ModusAlert, - d.ModusAutocomplete, - d.ModusBadge, - d.ModusBreadcrumb, - d.ModusButton, - d.ModusCard, - d.ModusCheckbox, - d.ModusChip, - d.ModusDataTable, - d.ModusDateInput, - d.ModusDatePicker, - d.ModusDropdown, - d.ModusFileDropzone, - d.ModusIcon, - d.ModusList, - d.ModusListItem, - d.ModusMessage, - d.ModusModal, - d.ModusNavbar, - d.ModusNavbarAppsMenu, - d.ModusNavbarButtonMenu, - d.ModusNavbarMainMenu, - d.ModusNavbarNotificationsMenu, - d.ModusNavbarProfileMenu, - d.ModusNavbarSearchOverlay, - d.ModusNumberInput, - d.ModusPagination, - d.ModusProgressBar, - d.ModusRadioGroup, - d.ModusSelect, - d.ModusSentimentScale, - d.ModusSideNavigation, - d.ModusSideNavigationItem, - d.ModusSlider, - d.ModusSpinner, - d.ModusSwitch, - d.ModusTable, - d.ModusTableCellEditor, - d.ModusTableCellMain, - d.ModusTableColumnsVisibility, - d.ModusTableDropdownMenu, - d.ModusTableFillerColumn, - d.ModusTableRowActions, - d.ModusTableRowActionsCell, - d.ModusTableRowActionsMenu, - d.ModusTableToolbar, - d.ModusTabs, - d.ModusTextInput, - d.ModusTimePicker, - d.ModusToast, - d.ModusTooltip, - d.ModusTreeView, - d.ModusTreeViewItem -]; diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts deleted file mode 100644 index 5d4a57017..000000000 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-select', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: SelectValueAccessor, - multi: true - } - ] -}) -export class SelectValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts deleted file mode 100644 index f1c229300..000000000 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-autocomplete, modus-number-input, modus-text-input', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: TextValueAccessor, - multi: true - } - ] -}) -export class TextValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts b/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts deleted file mode 100644 index 6bb76a6d3..000000000 --- a/angular-workspace/ng16/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { Directive, ElementRef, HostListener } from '@angular/core'; -import { ControlValueAccessor } from '@angular/forms'; - -@Directive({}) -export class ValueAccessor implements ControlValueAccessor { - - private onChange: (value: any) => void = () => {/**/}; - private onTouched: () => void = () => {/**/}; - protected lastValue: any; - - constructor(protected el: ElementRef) {} - - writeValue(value: any) { - this.el.nativeElement.value = this.lastValue = value == null ? '' : value; - } - - handleChangeEvent(value: any) { - if (value !== this.lastValue) { - this.lastValue = value; - this.onChange(value); - } - } - - @HostListener('focusout') - _handleBlurEvent() { - this.onTouched(); - } - - registerOnChange(fn: (value: any) => void) { - this.onChange = fn; - } - registerOnTouched(fn: () => void) { - this.onTouched = fn; - } - - setDisabledState(isDisabled: boolean) { - this.el.nativeElement.disabled = isDisabled; - } -} diff --git a/angular-workspace/ng17/package-lock.json b/angular-workspace/ng17/package-lock.json index b7a7b8eb9..caac0c993 100644 --- a/angular-workspace/ng17/package-lock.json +++ b/angular-workspace/ng17/package-lock.json @@ -16,7 +16,7 @@ "@angular/platform-browser": "^17.2.2", "@angular/platform-browser-dynamic": "^17.2.2", "@angular/router": "^17.2.2", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.14.4" @@ -3530,9 +3530,9 @@ } }, "node_modules/@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "dependencies": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -6057,9 +6057,9 @@ "dev": true }, "node_modules/express": { - "version": "4.18.3", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.3.tgz", - "integrity": "sha512-6VyCijWQ+9O7WuVMTRBTl+cjNNIzD5cY5mQ1WM8r/LEkI2u8EYpOotESNwzNlyCn3g+dmjKYI6BmNneSr/FSRw==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", @@ -6067,7 +6067,7 @@ "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -6099,9 +6099,9 @@ } }, "node_modules/express/node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" diff --git a/angular-workspace/ng17/package.json b/angular-workspace/ng17/package.json index e2ce1c539..8f23bd3ac 100644 --- a/angular-workspace/ng17/package.json +++ b/angular-workspace/ng17/package.json @@ -18,7 +18,7 @@ "@angular/platform-browser": "^17.2.2", "@angular/platform-browser-dynamic": "^17.2.2", "@angular/router": "^17.2.2", - "@trimble-oss/modus-web-components": "0.22.0", + "@trimble-oss/modus-web-components": "0.27.0", "rxjs": "~7.8.1", "tslib": "^2.5.3", "zone.js": "~0.14.4" diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package-lock.json b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package-lock.json index f3cb1bed1..8539186ef 100644 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package-lock.json +++ b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package-lock.json @@ -1,12 +1,12 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng17", + "version": "0.27.0-ng17", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng17", + "version": "0.27.0-ng17", "license": "MIT", "dependencies": { "tslib": "^2.5.3" @@ -17,7 +17,7 @@ "peerDependencies": { "@angular/common": "^17.2.2", "@angular/core": "^17.2.2", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" } }, "node_modules/tslib": { diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package.json b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package.json index c8430f97d..805fe17c0 100644 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package.json +++ b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/package.json @@ -1,6 +1,6 @@ { "name": "@trimble-oss/modus-angular-components", - "version": "0.22.0-ng17", + "version": "0.27.0-ng17", "license": "MIT", "description": "Trimble Modus Angular Components Library", "homepage": "https://modus-web-components.trimble.com/", @@ -14,7 +14,7 @@ "peerDependencies": { "@angular/common": "^17.2.2", "@angular/core": "^17.2.2", - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "dependencies": { "tslib": "^2.5.3" diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts deleted file mode 100644 index b75904879..000000000 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/angular-component-lib/utils.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* eslint-disable */ -/* tslint:disable */ -import { fromEvent } from 'rxjs'; - -export const proxyInputs = (Cmp: any, inputs: string[]) => { - const Prototype = Cmp.prototype; - inputs.forEach((item) => { - Object.defineProperty(Prototype, item, { - get() { - return this.el[item]; - }, - set(val: any) { - this.z.runOutsideAngular(() => (this.el[item] = val)); - }, - /** - * In the event that proxyInputs is called - * multiple times re-defining these inputs - * will cause an error to be thrown. As a result - * we set configurable: true to indicate these - * properties can be changed. - */ - configurable: true, - }); - }); -}; - -export const proxyMethods = (Cmp: any, methods: string[]) => { - const Prototype = Cmp.prototype; - methods.forEach((methodName) => { - Prototype[methodName] = function () { - const args = arguments; - return this.z.runOutsideAngular(() => this.el[methodName].apply(this.el, args)); - }; - }); -}; - -export const proxyOutputs = (instance: any, el: any, events: string[]) => { - events.forEach((eventName) => (instance[eventName] = fromEvent(el, eventName))); -}; - -export const defineCustomElement = (tagName: string, customElement: any) => { - if (customElement !== undefined && typeof customElements !== 'undefined' && !customElements.get(tagName)) { - customElements.define(tagName, customElement); - } -}; - -// tslint:disable-next-line: only-arrow-functions -export function ProxyCmp(opts: { defineCustomElementFn?: () => void; inputs?: any; methods?: any }) { - const decorator = function (cls: any) { - const { defineCustomElementFn, inputs, methods } = opts; - - if (defineCustomElementFn !== undefined) { - defineCustomElementFn(); - } - - if (inputs) { - proxyInputs(cls, inputs); - } - if (methods) { - proxyMethods(cls, methods); - } - return cls; - }; - return decorator; -} diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts deleted file mode 100644 index a51d1d535..000000000 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/boolean-value-accessor.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-checkbox, modus-switch', - host: { - '(checkboxClick)': 'handleChangeEvent($event.target.checked)', - '(switchClick)': 'handleChangeEvent($event.target.checked)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: BooleanValueAccessor, - multi: true - } - ] -}) -export class BooleanValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } - writeValue(value: any) { - this.el.nativeElement.checked = this.lastValue = value == null ? false : value; - } -} diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts deleted file mode 100644 index a2b7be9e2..000000000 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/components.ts +++ /dev/null @@ -1,1653 +0,0 @@ -/* tslint:disable */ -/* auto-generated angular directive proxies */ -import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, EventEmitter, NgZone } from '@angular/core'; - -import { ProxyCmp, proxyOutputs } from './angular-component-lib/utils'; - -import { Components } from '@trimble-oss/modus-web-components'; - - -@ProxyCmp({ - inputs: ['ariaLabel'] -}) -@Component({ - selector: 'modus-accordion', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel'], -}) -export class ModusAccordion { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusAccordion extends Components.ModusAccordion {} - - -@ProxyCmp({ - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'] -}) -@Component({ - selector: 'modus-accordion-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'expandButtonType', 'expanded', 'headerText', 'icon', 'size'], -}) -export class ModusAccordionItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened']); - } -} - - -export declare interface ModusAccordionItem extends Components.ModusAccordionItem { - /** - * An event that fires on every accordion close. - */ - closed: EventEmitter>; - /** - * An event that fires on every accordion open. - */ - opened: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'size', 'visibleItemCount'] -}) -@Component({ - selector: 'modus-action-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'size', 'visibleItemCount'], -}) -export class ModusActionBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['actionBarClick']); - } -} - - -export declare interface ModusActionBar extends Components.ModusActionBar { - /** - * (optional) An event that fires on action item click. - */ - actionBarClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'] -}) -@Component({ - selector: 'modus-alert', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'buttonAriaLabel', 'buttonText', 'dismissible', 'message', 'type'], -}) -export class ModusAlert { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick', 'actionClick']); - } -} - - -export declare interface ModusAlert extends Components.ModusAlert { - /** - * An event that fires when the alert is dismissed - */ - dismissClick: EventEmitter>; - /** - * An event that firest when the action button is clicked - */ - actionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'] -}) -@Component({ - selector: 'modus-autocomplete', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'clearable', 'disableCloseOnSelect', 'disabled', 'dropdownMaxHeight', 'dropdownZIndex', 'errorText', 'includeSearchIcon', 'label', 'multiple', 'noResultsFoundSubtext', 'noResultsFoundText', 'options', 'placeholder', 'readOnly', 'required', 'showNoResultsFoundMessage', 'showOptionsOnFocus', 'size', 'value'], -}) -export class ModusAutocomplete { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['optionSelected', 'valueChange']); - } -} - - -export declare interface ModusAutocomplete extends Components.ModusAutocomplete { - /** - * An event that fires when a dropdown option is selected. Emits the option id. - */ - optionSelected: EventEmitter>; - /** - * An event that fires when the input value changes. Emits the value string. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'color', 'size', 'type'] -}) -@Component({ - selector: 'modus-badge', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'color', 'size', 'type'], -}) -export class ModusBadge { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusBadge extends Components.ModusBadge {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'] -}) -@Component({ - selector: 'modus-breadcrumb', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'crumbs', 'underlineLinks'], -}) -export class ModusBreadcrumb { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['crumbClick']); - } -} - - -import type { Crumb as IModusBreadcrumbCrumb } from '@trimble-oss/modus-web-components'; - -export declare interface ModusBreadcrumb extends Components.ModusBreadcrumb { - /** - * (optional) An event that fires on breadcrumb click. - */ - crumbClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], - methods: ['focusButton'] -}) -@Component({ - selector: 'modus-button', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaDisabled', 'ariaLabel', 'buttonStyle', 'color', 'disabled', 'iconOnly', 'leftIcon', 'rightIcon', 'showCaret', 'size', 'type'], -}) -export class ModusButton { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusButton extends Components.ModusButton { - /** - * (optional) An event that fires on button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'] -}) -@Component({ - selector: 'modus-card', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'borderRadius', 'height', 'showCardBorder', 'showShadowOnHover', 'width'], -}) -export class ModusCard { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusCard extends Components.ModusCard {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], - methods: ['focusCheckbox'] -}) -@Component({ - selector: 'modus-checkbox', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'indeterminate', 'label', 'size', 'stopPropagation', 'tabIndexValue'], -}) -export class ModusCheckbox { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick']); - } -} - - -export declare interface ModusCheckbox extends Components.ModusCheckbox { - /** - * An event that fires on checkbox click. - */ - checkboxClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'] -}) -@Component({ - selector: 'modus-chip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'chipStyle', 'disabled', 'hasError', 'imageUrl', 'maxWidth', 'showCheckmark', 'showClose', 'size', 'value'], -}) -export class ModusChip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['chipClick', 'closeClick']); - } -} - - -export declare interface ModusChip extends Components.ModusChip { - /** - * An event that fires on chip click. - */ - chipClick: EventEmitter>; - /** - * An event that fires on close icon click. - */ - closeClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'] -}) -@Component({ - selector: 'modus-data-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columns', 'data', 'displayOptions', 'rowActions', 'selectionOptions', 'sortOptions'], -}) -export class ModusDataTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellLinkClick', 'rowDoubleClick', 'selection', 'sort', 'rowActionClick']); - } -} - - -import type { ModusDataTableCellLink as IModusDataTableModusDataTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableSortEvent as IModusDataTableModusDataTableSortEvent } from '@trimble-oss/modus-web-components'; -import type { ModusDataTableRowActionClickEvent as IModusDataTableModusDataTableRowActionClickEvent } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDataTable extends Components.ModusDataTable { - /** - * An event that fires on cell link click. - */ - cellLinkClick: EventEmitter>; - /** - * An event that fires on row double click. - */ - rowDoubleClick: EventEmitter>; - /** - * An event that fires on selection change. - */ - selection: EventEmitter>; - /** - * An event that fires on column sort. - */ - sort: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], - methods: ['focusInput', 'validate'] -}) -@Component({ - selector: 'modus-date-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'altFormats', 'ariaLabel', 'autoFocusInput', 'disableValidation', 'disabled', 'errorText', 'fillerDate', 'format', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'showCalendarIcon', 'size', 'type', 'validText', 'value'], -}) -export class ModusDateInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['calendarIconClicked', 'dateInputBlur', 'valueChange']); - } -} - - -import type { ModusDateInputEventDetails as IModusDateInputModusDateInputEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusDateInput extends Components.ModusDateInput { - /** - * An event that fires on calendar icon click. - */ - calendarIconClicked: EventEmitter>; - /** - * An event that fires on input value out of focus. - */ - dateInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['label'] -}) -@Component({ - selector: 'modus-date-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['label'], -}) -export class ModusDatePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusDatePicker extends Components.ModusDatePicker {} - - -@ProxyCmp({ - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'] -}) -@Component({ - selector: 'modus-dropdown', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animateList', 'ariaLabel', 'customPlacement', 'disabled', 'placement', 'showDropdownListBorder', 'toggleElementId'], -}) -export class ModusDropdown { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dropdownClose']); - } -} - - -export declare interface ModusDropdown extends Components.ModusDropdown { - /** - * An event that fires on dropdown close. - */ - dropdownClose: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], - methods: ['addFile', 'getError', 'getFiles', 'removeFile'] -}) -@Component({ - selector: 'modus-file-dropzone', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'description', 'dropzoneHeight', 'dropzoneWidth', 'includeStateIcon', 'label', 'maxFileCount', 'maxFileNameLength', 'maxTotalFileSizeBytes', 'multiple'], -}) -export class ModusFileDropzone { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['files']); - } -} - - -export declare interface ModusFileDropzone extends Components.ModusFileDropzone { - /** - * An event that fires when files have been added or removed, regardless of whether they're valid. - */ - files: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'name', 'size'] -}) -@Component({ - selector: 'modus-icon', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'name', 'size'], -}) -export class ModusIcon { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['iconClick']); - } -} - - -export declare interface ModusIcon extends Components.ModusIcon { - /** - * (optional) The click handler function - */ - iconClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-list', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusList { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusList extends Components.ModusList {} - - -@ProxyCmp({ - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-list-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'disabled', 'leftIcon', 'selected', 'size', 'subText', 'type', 'wrapSubText'], -}) -export class ModusListItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemClick']); - } -} - - -export declare interface ModusListItem extends Components.ModusListItem { - /** - * An event that fires on list item click - */ - itemClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'icon', 'type'] -}) -@Component({ - selector: 'modus-message', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'icon', 'type'], -}) -export class ModusMessage { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusMessage extends Components.ModusMessage {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], - methods: ['close', 'open'] -}) -@Component({ - selector: 'modus-modal', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backdrop', 'headerText', 'primaryButtonAriaLabel', 'primaryButtonDisabled', 'primaryButtonText', 'secondaryButtonAriaLabel', 'secondaryButtonDisabled', 'secondaryButtonText', 'zIndex'], -}) -export class ModusModal { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['closed', 'opened', 'primaryButtonClick', 'secondaryButtonClick']); - } -} - - -export declare interface ModusModal extends Components.ModusModal { - /** - * An event that fires on modal close. - */ - closed: EventEmitter>; - /** - * An event that fires on modal open. - */ - opened: EventEmitter>; - /** - * An event that fires on primary button click. - */ - primaryButtonClick: EventEmitter>; - /** - * An event that fires on secondary button click. - */ - secondaryButtonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], - methods: ['hideMainMenu'] -}) -@Component({ - selector: 'modus-navbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'buttons', 'enableSearchOverlay', 'helpTooltip', 'helpUrl', 'logoOptions', 'profileMenuOptions', 'reverse', 'searchTooltip', 'showAppsMenu', 'showHelp', 'showMainMenu', 'showNotifications', 'showPendoPlaceholder', 'showProfile', 'showSearch', 'showShadow', 'variant'], -}) -export class ModusNavbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appsMenuOpen', 'appsMenuAppOpen', 'buttonClick', 'helpOpen', 'mainMenuClick', 'notificationsMenuOpen', 'productLogoClick', 'profileMenuLinkClick', 'profileMenuOpen', 'profileMenuSignOutClick', 'searchChange', 'searchMenuClick']); - } -} - - -import type { ModusNavbarApp as IModusNavbarModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbar extends Components.ModusNavbar { - /** - * An event that fires when the apps menu opens. - */ - appsMenuOpen: EventEmitter>; - /** - * An event that fires when an apps menu app opens. - */ - appsMenuAppOpen: EventEmitter>; - /** - * An event that fires when a button in the custom button list is clicked. - */ - buttonClick: EventEmitter>; - /** - * An event that fires when the help link opens. - */ - helpOpen: EventEmitter>; - /** - * An event that fires on main menu click. - */ - mainMenuClick: EventEmitter>; - /** - * An event that fires when the notifications menu opens. - */ - notificationsMenuOpen: EventEmitter>; - /** - * An event that fires on product logo click. - */ - productLogoClick: EventEmitter>; - /** - * An event that fires on profile menu link click. - */ - profileMenuLinkClick: EventEmitter>; - /** - * An event that fires when the profile menu opens. - */ - profileMenuOpen: EventEmitter>; - /** - * An event that fires on profile menu sign out click. - */ - profileMenuSignOutClick: EventEmitter>; - /** - * An event that fires on search value change. - */ - searchChange: EventEmitter>; - /** - * An event that fires on search button click. - */ - searchMenuClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['apps', 'reverse'] -}) -@Component({ - selector: 'modus-navbar-apps-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['apps', 'reverse'], -}) -export class ModusNavbarAppsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['appOpen']); - } -} - - -import type { ModusNavbarApp as IModusNavbarAppsMenuModusNavbarApp } from '@trimble-oss/modus-web-components'; - -export declare interface ModusNavbarAppsMenu extends Components.ModusNavbarAppsMenu { - - appOpen: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-button-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarButtonMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarButtonMenu extends Components.ModusNavbarButtonMenu {} - - -@ProxyCmp({ - inputs: ['navbarId'] -}) -@Component({ - selector: 'modus-navbar-main-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['navbarId'], -}) -export class ModusNavbarMainMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarMainMenu extends Components.ModusNavbarMainMenu {} - - -@ProxyCmp({ - inputs: ['reverse'] -}) -@Component({ - selector: 'modus-navbar-notifications-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['reverse'], -}) -export class ModusNavbarNotificationsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusNavbarNotificationsMenu extends Components.ModusNavbarNotificationsMenu {} - - -@ProxyCmp({ - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'] -}) -@Component({ - selector: 'modus-navbar-profile-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['avatarUrl', 'email', 'initials', 'links', 'reverse', 'signOutText', 'username', 'variant'], -}) -export class ModusNavbarProfileMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['linkClick', 'signOutClick']); - } -} - - -export declare interface ModusNavbarProfileMenu extends Components.ModusNavbarProfileMenu { - - linkClick: EventEmitter>; - - signOutClick: EventEmitter>; -} - - -@ProxyCmp({ -}) -@Component({ - selector: 'modus-navbar-search-overlay', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: [], -}) -export class ModusNavbarSearchOverlay { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['close', 'search']); - } -} - - -export declare interface ModusNavbarSearchOverlay extends Components.ModusNavbarSearchOverlay { - /** - * An event that fires on clicking on close button of search overlay - */ - close: EventEmitter>; - /** - * An event that fires on search value change. - */ - search: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-number-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'maxValue', 'minValue', 'placeholder', 'readOnly', 'required', 'size', 'step', 'textAlign', 'validText', 'value'], -}) -export class ModusNumberInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusNumberInput extends Components.ModusNumberInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'] -}) -@Component({ - selector: 'modus-pagination', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activePage', 'ariaLabel', 'maxPage', 'minPage', 'nextPageButtonText', 'prevPageButtonText', 'size'], -}) -export class ModusPagination { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['pageChange']); - } -} - - -export declare interface ModusPagination extends Components.ModusPagination { - /** - * An event that fires on page change. - */ - pageChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'] -}) -@Component({ - selector: 'modus-progress-bar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'backgroundColor', 'color', 'maxValue', 'minValue', 'size', 'text', 'textColor', 'value'], -}) -export class ModusProgressBar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusProgressBar extends Components.ModusProgressBar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'] -}) -@Component({ - selector: 'modus-radio-group', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checkedId', 'name', 'radioButtons', 'size'], -}) -export class ModusRadioGroup { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['buttonClick']); - } -} - - -export declare interface ModusRadioGroup extends Components.ModusRadioGroup { - /** - * Fires on radio button click. - */ - buttonClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-select', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'errorText', 'helperText', 'label', 'options', 'optionsDisplayProp', 'placeholder', 'required', 'size', 'validText', 'value'], -}) -export class ModusSelect { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'inputBlur']); - } -} - - -export declare interface ModusSelect extends Components.ModusSelect { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on input blur. - */ - inputBlur: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'type'] -}) -@Component({ - selector: 'modus-sentiment-scale', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'type'], -}) -export class ModusSentimentScale { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sentimentSelection']); - } -} - - -export declare interface ModusSentimentScale extends Components.ModusSentimentScale { - /** - * An event that fires the selected sentiment. - */ - sentimentSelection: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'] -}) -@Component({ - selector: 'modus-side-navigation', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapseOnClickOutside', 'data', 'expanded', 'maxWidth', 'mode', 'targetContent'], -}) -export class ModusSideNavigation { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavExpand']); - } -} - - -export declare interface ModusSideNavigation extends Components.ModusSideNavigation { - /** - * An event that fires on side navigation panel collapse & expand. - */ - sideNavExpand: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], - methods: ['focusItem'] -}) -@Component({ - selector: 'modus-side-navigation-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disableSelection', 'disabled', 'label', 'menuIcon', 'selected', 'showExpandIcon'], -}) -export class ModusSideNavigationItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['sideNavItemClicked', 'sideNavItemFocus']); - } -} - - -export declare interface ModusSideNavigationItem extends Components.ModusSideNavigationItem { - /** - * An event that fires when mouse click or `Enter` key press on an item. - */ - sideNavItemClicked: EventEmitter>; - /** - * An event that fires when an item is in focus. - */ - sideNavItemFocus: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'] -}) -@Component({ - selector: 'modus-slider', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'label', 'maxValue', 'minValue', 'value'], -}) -export class ModusSlider { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange', 'valueInput']); - } -} - - -export declare interface ModusSlider extends Components.ModusSlider { - /** - * An event that fires on slider value change. - */ - valueChange: EventEmitter>; - /** - * An event that fires on slider value input. - */ - valueInput: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['color', 'size'] -}) -@Component({ - selector: 'modus-spinner', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'size'], -}) -export class ModusSpinner { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusSpinner extends Components.ModusSpinner {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'] -}) -@Component({ - selector: 'modus-switch', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'checked', 'disabled', 'label', 'size'], -}) -export class ModusSwitch { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['switchClick']); - } -} - - -export declare interface ModusSwitch extends Components.ModusSwitch { - /** - * An event that fires on switch click. - */ - switchClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], - methods: ['getColumnData', 'toggleColumnVisibility'] -}) -@Component({ - selector: 'modus-table', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnReorder', 'columnResize', 'columns', 'data', 'defaultSort', 'density', 'displayOptions', 'fullWidth', 'hover', 'manualPaginationOptions', 'manualSortingOptions', 'maxHeight', 'maxWidth', 'pageSizeList', 'pagination', 'rowActions', 'rowSelection', 'rowSelectionOptions', 'rowsExpandable', 'showSortIconOnHover', 'sort', 'sortIconStyle', 'summaryRow', 'toolbar', 'toolbarOptions', 'wrapText'], -}) -export class ModusTable { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['cellValueChange', 'cellLinkClick', 'columnOrderChange', 'columnSizingChange', 'columnVisibilityChange', 'rowActionClick', 'rowExpanded', 'rowSelectionChange', 'sortChange', 'paginationChange']); - } -} - - -import type { ModusTableCellValueChange as IModusTableModusTableCellValueChange } from '@trimble-oss/modus-web-components'; -import type { ModusTableCellLink as IModusTableModusTableCellLink } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnOrderState as IModusTableModusTableColumnOrderState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnSizingState as IModusTableModusTableColumnSizingState } from '@trimble-oss/modus-web-components'; -import type { ModusTableColumnVisibilityState as IModusTableModusTableColumnVisibilityState } from '@trimble-oss/modus-web-components'; -import type { ModusTableRowActionClick as IModusTableModusTableRowActionClick } from '@trimble-oss/modus-web-components'; -import type { ModusTableExpandedState as IModusTableModusTableExpandedState } from '@trimble-oss/modus-web-components'; -import type { ModusTableSortingState as IModusTableModusTableSortingState } from '@trimble-oss/modus-web-components'; -import type { ModusTablePaginationState as IModusTableModusTablePaginationState } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTable extends Components.ModusTable { - /** - * Emits the cell value that was edited - */ - cellValueChange: EventEmitter>; - /** - * Emits the link that was clicked - */ - cellLinkClick: EventEmitter>; - /** - * Emits columns in the updated order - */ - columnOrderChange: EventEmitter>; - /** - * Emits latest column size - */ - columnSizingChange: EventEmitter>; - /** - * Emits visibility state of each column - */ - columnVisibilityChange: EventEmitter>; - /** - * An event that fires when a row action is clicked. - */ - rowActionClick: EventEmitter>; - /** - * Emits expanded state of the columns - */ - rowExpanded: EventEmitter>; - /** - * Emits rows selected - */ - rowSelectionChange: EventEmitter>; - /** - * Emits column sort order - */ - sortChange: EventEmitter>; - /** - * Emits selected page index and size - */ - paginationChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-editor', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['args', 'keyDown', 'type', 'value', 'valueChange'], -}) -export class ModusTableCellEditor { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellEditor extends Components.ModusTableCellEditor {} - - -@ProxyCmp({ - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'] -}) -@Component({ - selector: 'modus-table-cell-main', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cell', 'context', 'hasRowsExpandable', 'valueChange'], -}) -export class ModusTableCellMain { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableCellMain extends Components.ModusTableCellMain {} - - -@ProxyCmp({ - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'] -}) -@Component({ - selector: 'modus-table-columns-visibility', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['columnsVisibility', 'getAllLeafColumns', 'maxHeight', 'menuIconContainerRef', 'showDropdown', 'toggleDropdown'], -}) -export class ModusTableColumnsVisibility { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableColumnsVisibility extends Components.ModusTableColumnsVisibility {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-dropdown-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableDropdownMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableDropdownMenu extends Components.ModusTableDropdownMenu {} - - -@ProxyCmp({ - inputs: ['cellBorderless', 'container', 'summaryRow'] -}) -@Component({ - selector: 'modus-table-filler-column', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cellBorderless', 'container', 'summaryRow'], -}) -export class ModusTableFillerColumn { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableFillerColumn extends Components.ModusTableFillerColumn {} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActions { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['overflowRowActions']); - } -} - - -export declare interface ModusTableRowActions extends Components.ModusTableRowActions { - - overflowRowActions: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['context', 'row'] -}) -@Component({ - selector: 'modus-table-row-actions-cell', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context', 'row'], -}) -export class ModusTableRowActionsCell { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsCell extends Components.ModusTableRowActionsCell {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-row-actions-menu', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableRowActionsMenu { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableRowActionsMenu extends Components.ModusTableRowActionsMenu {} - - -@ProxyCmp({ - inputs: ['context'] -}) -@Component({ - selector: 'modus-table-toolbar', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['context'], -}) -export class ModusTableToolbar { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTableToolbar extends Components.ModusTableToolbar {} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'] -}) -@Component({ - selector: 'modus-tabs', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'fullWidth', 'size', 'tabs'], -}) -export class ModusTabs { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['tabChange']); - } -} - - -export declare interface ModusTabs extends Components.ModusTabs { - /** - * An event that fires on tab change. - */ - tabChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-text-input', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'autoFocusInput', 'autocomplete', 'clearable', 'disabled', 'errorText', 'helperText', 'includePasswordTextToggle', 'includeSearchIcon', 'inputmode', 'label', 'maxLength', 'minLength', 'placeholder', 'readOnly', 'required', 'size', 'textAlign', 'type', 'validText', 'value'], -}) -export class ModusTextInput { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['valueChange']); - } -} - - -export declare interface ModusTextInput extends Components.ModusTextInput { - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], - methods: ['focusInput'] -}) -@Component({ - selector: 'modus-time-picker', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowedCharsRegex', 'ampm', 'ariaLabel', 'autoFocusInput', 'autoFormat', 'disableValidation', 'disabled', 'errorText', 'helperText', 'label', 'max', 'min', 'placeholder', 'readOnly', 'required', 'size', 'validText', 'value'], -}) -export class ModusTimePicker { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['timeInputBlur', 'valueChange']); - } -} - - -import type { ModusTimePickerEventDetails as IModusTimePickerModusTimePickerEventDetails } from '@trimble-oss/modus-web-components'; - -export declare interface ModusTimePicker extends Components.ModusTimePicker { - /** - * An event that fires on input value out of focus. - */ - timeInputBlur: EventEmitter>; - /** - * An event that fires on input value change. - */ - valueChange: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'] -}) -@Component({ - selector: 'modus-toast', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'dismissible', 'showIcon', 'type'], -}) -export class ModusToast { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['dismissClick']); - } -} - - -export declare interface ModusToast extends Components.ModusToast { - /** - * An event that fires when the toast is dismissed - */ - dismissClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['ariaLabel', 'disabled', 'position', 'text'] -}) -@Component({ - selector: 'modus-tooltip', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['ariaLabel', 'disabled', 'position', 'text'], -}) -export class ModusTooltip { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - } -} - - -export declare interface ModusTooltip extends Components.ModusTooltip {} - - -@ProxyCmp({ - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'] -}) -@Component({ - selector: 'modus-tree-view', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['borderless', 'checkboxSelection', 'checkedItems', 'disableTabbing', 'expandedItems', 'multiCheckboxSelection', 'multiSelection', 'selectedItems', 'size'], -}) -export class ModusTreeView { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['itemActionClick']); - } -} - - -export declare interface ModusTreeView extends Components.ModusTreeView { - /** - * Fired when an action is clicked within any tree item. Includes both the `actionId` and `nodeId` of the action and item, respectively. - */ - itemActionClick: EventEmitter>; -} - - -@ProxyCmp({ - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], - methods: ['focusItem', 'focusCheckbox'] -}) -@Component({ - selector: 'modus-tree-view-item', - changeDetection: ChangeDetectionStrategy.OnPush, - template: '', - // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['actions', 'disabled', 'draggableItem', 'droppableItem', 'editable', 'label', 'nodeId', 'tabIndexValue'], -}) -export class ModusTreeViewItem { - protected el: HTMLElement; - constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) { - c.detach(); - this.el = r.nativeElement; - proxyOutputs(this, this.el, ['checkboxClick', 'itemClick', 'itemExpandToggle', 'actionClick']); - } -} - - -export declare interface ModusTreeViewItem extends Components.ModusTreeViewItem { - /** - * An event that fires on tree item checkbox click - */ - checkboxClick: EventEmitter>; - /** - * An event that fires on tree item click - */ - itemClick: EventEmitter>; - /** - * An event that fires on tree item expand/collapse - */ - itemExpandToggle: EventEmitter>; - /** - * Fired when an action button within the tree item is clicked. Includes the `actionId`. - */ - actionClick: EventEmitter>; -} - - diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts deleted file mode 100644 index b0e106326..000000000 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/index.ts +++ /dev/null @@ -1,61 +0,0 @@ - -import * as d from './components'; - -export const DIRECTIVES = [ - d.ModusAccordion, - d.ModusAccordionItem, - d.ModusActionBar, - d.ModusAlert, - d.ModusAutocomplete, - d.ModusBadge, - d.ModusBreadcrumb, - d.ModusButton, - d.ModusCard, - d.ModusCheckbox, - d.ModusChip, - d.ModusDataTable, - d.ModusDateInput, - d.ModusDatePicker, - d.ModusDropdown, - d.ModusFileDropzone, - d.ModusIcon, - d.ModusList, - d.ModusListItem, - d.ModusMessage, - d.ModusModal, - d.ModusNavbar, - d.ModusNavbarAppsMenu, - d.ModusNavbarButtonMenu, - d.ModusNavbarMainMenu, - d.ModusNavbarNotificationsMenu, - d.ModusNavbarProfileMenu, - d.ModusNavbarSearchOverlay, - d.ModusNumberInput, - d.ModusPagination, - d.ModusProgressBar, - d.ModusRadioGroup, - d.ModusSelect, - d.ModusSentimentScale, - d.ModusSideNavigation, - d.ModusSideNavigationItem, - d.ModusSlider, - d.ModusSpinner, - d.ModusSwitch, - d.ModusTable, - d.ModusTableCellEditor, - d.ModusTableCellMain, - d.ModusTableColumnsVisibility, - d.ModusTableDropdownMenu, - d.ModusTableFillerColumn, - d.ModusTableRowActions, - d.ModusTableRowActionsCell, - d.ModusTableRowActionsMenu, - d.ModusTableToolbar, - d.ModusTabs, - d.ModusTextInput, - d.ModusTimePicker, - d.ModusToast, - d.ModusTooltip, - d.ModusTreeView, - d.ModusTreeViewItem -]; diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts deleted file mode 100644 index 5d4a57017..000000000 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/select-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-select', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: SelectValueAccessor, - multi: true - } - ] -}) -export class SelectValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts deleted file mode 100644 index f1c229300..000000000 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/text-value-accessor.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Directive, ElementRef } from '@angular/core'; -import { NG_VALUE_ACCESSOR } from '@angular/forms'; - -import { ValueAccessor } from './value-accessor'; - -@Directive({ - /* tslint:disable-next-line:directive-selector */ - selector: 'modus-autocomplete, modus-number-input, modus-text-input', - host: { - '(valueChange)': 'handleChangeEvent($event.target.value)' - }, - providers: [ - { - provide: NG_VALUE_ACCESSOR, - useExisting: TextValueAccessor, - multi: true - } - ] -}) -export class TextValueAccessor extends ValueAccessor { - constructor(el: ElementRef) { - super(el); - } -} diff --git a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts b/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts deleted file mode 100644 index 6bb76a6d3..000000000 --- a/angular-workspace/ng17/projects/trimble-oss/modus-angular-components/src/lib/stencil-generated/value-accessor.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { Directive, ElementRef, HostListener } from '@angular/core'; -import { ControlValueAccessor } from '@angular/forms'; - -@Directive({}) -export class ValueAccessor implements ControlValueAccessor { - - private onChange: (value: any) => void = () => {/**/}; - private onTouched: () => void = () => {/**/}; - protected lastValue: any; - - constructor(protected el: ElementRef) {} - - writeValue(value: any) { - this.el.nativeElement.value = this.lastValue = value == null ? '' : value; - } - - handleChangeEvent(value: any) { - if (value !== this.lastValue) { - this.lastValue = value; - this.onChange(value); - } - } - - @HostListener('focusout') - _handleBlurEvent() { - this.onTouched(); - } - - registerOnChange(fn: (value: any) => void) { - this.onChange = fn; - } - registerOnTouched(fn: () => void) { - this.onTouched = fn; - } - - setDisabledState(isDisabled: boolean) { - this.el.nativeElement.disabled = isDisabled; - } -} diff --git a/angular-workspace/test-ng14/package-lock.json b/angular-workspace/test-ng14/package-lock.json index 50d939472..3753c3427 100644 --- a/angular-workspace/test-ng14/package-lock.json +++ b/angular-workspace/test-ng14/package-lock.json @@ -5942,17 +5942,17 @@ "dev": true }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -5989,34 +5989,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "node_modules/express/node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/express/node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" @@ -6055,21 +6031,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "node_modules/express/node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/express/node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -16629,17 +16590,17 @@ "dev": true }, "express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -16673,30 +16634,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - } - }, "cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true }, "debug": { @@ -16729,18 +16670,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - } - }, "statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", diff --git a/angular-workspace/test-ng15/package-lock.json b/angular-workspace/test-ng15/package-lock.json index 78af146a1..770d17519 100644 --- a/angular-workspace/test-ng15/package-lock.json +++ b/angular-workspace/test-ng15/package-lock.json @@ -5962,17 +5962,17 @@ "dev": true }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -6009,34 +6009,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "node_modules/express/node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/express/node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" @@ -6075,21 +6051,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "node_modules/express/node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/express/node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -16969,17 +16930,17 @@ "dev": true }, "express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -17013,30 +16974,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - } - }, "cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true }, "debug": { @@ -17069,18 +17010,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "requires": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - } - }, "statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", diff --git a/angular-workspace/test-web-components/package-lock.json b/angular-workspace/test-web-components/package-lock.json index 70cfb92a6..7269bd290 100644 --- a/angular-workspace/test-web-components/package-lock.json +++ b/angular-workspace/test-web-components/package-lock.json @@ -5943,17 +5943,17 @@ "dev": true }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -5990,34 +5990,10 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "node_modules/express/node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.4", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.11.0", - "raw-body": "2.5.1", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/express/node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" @@ -6056,21 +6032,6 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", "dev": true }, - "node_modules/express/node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/express/node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", diff --git a/package.json b/package.json index b6f4813ed..81c22ef39 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "author": "Trimble Inc", "scripts": { "prettier": "npx prettier --write \"**/*.yml\"", - "build-angular": "cd angular-workspace/ng14 && npm ci && npm run build && cd ../ng15 && npm ci && npm run build && cd ../ng16 && npm ci && npm run build && cd ../ng17 && npm ci && npm run build", + "build-angular": "cd angular-workspace/ng14 && npm i && npm run build && cd ../ng15 && npm i && npm run build && cd ../ng16 && npm i && npm run build && cd ../ng17 && npm i && npm run build", "update-mwc-dependants": "cd angular-workspace/ng14/projects/trimble-oss/modus-angular-components && npx npm-check-updates -u --dep peer @trimble-oss* && npm i && cd ../../../../ng15/projects/trimble-oss/modus-angular-components && npx npm-check-updates -u --dep peer @trimble-oss* && npm i && cd ../../../../ng16/projects/trimble-oss/modus-angular-components && npx npm-check-updates -u --dep peer @trimble-oss* && npm i && cd ../../../../ng17/projects/trimble-oss/modus-angular-components && npx npm-check-updates -u --dep peer @trimble-oss* && npm i && cd ../../../../../react-workspace/react-17 && npx npm-check-updates -u @trimble-oss* && npm i && cd ../react-18 && npx npm-check-updates -u @trimble-oss* && npm i" }, "engines": { diff --git a/react-workspace/react-17/package-lock.json b/react-workspace/react-17/package-lock.json index 3ef99e504..2dbf2fd3b 100644 --- a/react-workspace/react-17/package-lock.json +++ b/react-workspace/react-17/package-lock.json @@ -1,15 +1,15 @@ { "name": "@trimble-oss/modus-react-components", - "version": "0.22.0-react17", + "version": "0.27.0-react17", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@trimble-oss/modus-react-components", - "version": "0.22.0-react17", + "version": "0.27.0-react17", "license": "MIT", "dependencies": { - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "devDependencies": { "@types/jest": "23.3.9", @@ -1066,9 +1066,9 @@ } }, "node_modules/@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "dependencies": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -4980,9 +4980,9 @@ "integrity": "sha512-69WEY1PaZROaGYUrseng4/4sMYnRGhDe1vM6888CnWekGz/wuCnvqwOoOuKGYivnaiI4BVmZq4WKWhvahyj3/g==" }, "@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "requires": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", diff --git a/react-workspace/react-17/package.json b/react-workspace/react-17/package.json index cf8498203..696429cea 100644 --- a/react-workspace/react-17/package.json +++ b/react-workspace/react-17/package.json @@ -1,6 +1,6 @@ { "name": "@trimble-oss/modus-react-components", - "version": "0.22.0-react17", + "version": "0.27.0-react17", "description": "Trimble Modus React Component Library", "homepage": "https://modus-web-components.trimble.com/", "bugs": { @@ -33,7 +33,7 @@ ] }, "dependencies": { - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "devDependencies": { "@types/jest": "23.3.9", diff --git a/react-workspace/react-17/src/components/stencil-generated/index.ts b/react-workspace/react-17/src/components/stencil-generated/index.ts deleted file mode 100644 index 460273102..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/index.ts +++ /dev/null @@ -1,66 +0,0 @@ -/* eslint-disable */ -/* tslint:disable */ -/* auto-generated react proxies */ -import { createReactComponent } from './react-component-lib'; - -import type { JSX } from '@trimble-oss/modus-web-components'; - -import { defineCustomElements } from '@trimble-oss/modus-web-components/loader'; - -defineCustomElements(); -export const ModusAccordion = /*@__PURE__*/createReactComponent('modus-accordion'); -export const ModusAccordionItem = /*@__PURE__*/createReactComponent('modus-accordion-item'); -export const ModusActionBar = /*@__PURE__*/createReactComponent('modus-action-bar'); -export const ModusAlert = /*@__PURE__*/createReactComponent('modus-alert'); -export const ModusAutocomplete = /*@__PURE__*/createReactComponent('modus-autocomplete'); -export const ModusBadge = /*@__PURE__*/createReactComponent('modus-badge'); -export const ModusBreadcrumb = /*@__PURE__*/createReactComponent('modus-breadcrumb'); -export const ModusButton = /*@__PURE__*/createReactComponent('modus-button'); -export const ModusCard = /*@__PURE__*/createReactComponent('modus-card'); -export const ModusCheckbox = /*@__PURE__*/createReactComponent('modus-checkbox'); -export const ModusChip = /*@__PURE__*/createReactComponent('modus-chip'); -export const ModusDataTable = /*@__PURE__*/createReactComponent('modus-data-table'); -export const ModusDateInput = /*@__PURE__*/createReactComponent('modus-date-input'); -export const ModusDatePicker = /*@__PURE__*/createReactComponent('modus-date-picker'); -export const ModusDropdown = /*@__PURE__*/createReactComponent('modus-dropdown'); -export const ModusFileDropzone = /*@__PURE__*/createReactComponent('modus-file-dropzone'); -export const ModusIcon = /*@__PURE__*/createReactComponent('modus-icon'); -export const ModusList = /*@__PURE__*/createReactComponent('modus-list'); -export const ModusListItem = /*@__PURE__*/createReactComponent('modus-list-item'); -export const ModusMessage = /*@__PURE__*/createReactComponent('modus-message'); -export const ModusModal = /*@__PURE__*/createReactComponent('modus-modal'); -export const ModusNavbar = /*@__PURE__*/createReactComponent('modus-navbar'); -export const ModusNavbarAppsMenu = /*@__PURE__*/createReactComponent('modus-navbar-apps-menu'); -export const ModusNavbarButtonMenu = /*@__PURE__*/createReactComponent('modus-navbar-button-menu'); -export const ModusNavbarMainMenu = /*@__PURE__*/createReactComponent('modus-navbar-main-menu'); -export const ModusNavbarNotificationsMenu = /*@__PURE__*/createReactComponent('modus-navbar-notifications-menu'); -export const ModusNavbarProfileMenu = /*@__PURE__*/createReactComponent('modus-navbar-profile-menu'); -export const ModusNavbarSearchOverlay = /*@__PURE__*/createReactComponent('modus-navbar-search-overlay'); -export const ModusNumberInput = /*@__PURE__*/createReactComponent('modus-number-input'); -export const ModusPagination = /*@__PURE__*/createReactComponent('modus-pagination'); -export const ModusProgressBar = /*@__PURE__*/createReactComponent('modus-progress-bar'); -export const ModusRadioGroup = /*@__PURE__*/createReactComponent('modus-radio-group'); -export const ModusSelect = /*@__PURE__*/createReactComponent('modus-select'); -export const ModusSentimentScale = /*@__PURE__*/createReactComponent('modus-sentiment-scale'); -export const ModusSideNavigation = /*@__PURE__*/createReactComponent('modus-side-navigation'); -export const ModusSideNavigationItem = /*@__PURE__*/createReactComponent('modus-side-navigation-item'); -export const ModusSlider = /*@__PURE__*/createReactComponent('modus-slider'); -export const ModusSpinner = /*@__PURE__*/createReactComponent('modus-spinner'); -export const ModusSwitch = /*@__PURE__*/createReactComponent('modus-switch'); -export const ModusTable = /*@__PURE__*/createReactComponent('modus-table'); -export const ModusTableCellEditor = /*@__PURE__*/createReactComponent('modus-table-cell-editor'); -export const ModusTableCellMain = /*@__PURE__*/createReactComponent('modus-table-cell-main'); -export const ModusTableColumnsVisibility = /*@__PURE__*/createReactComponent('modus-table-columns-visibility'); -export const ModusTableDropdownMenu = /*@__PURE__*/createReactComponent('modus-table-dropdown-menu'); -export const ModusTableFillerColumn = /*@__PURE__*/createReactComponent('modus-table-filler-column'); -export const ModusTableRowActions = /*@__PURE__*/createReactComponent('modus-table-row-actions'); -export const ModusTableRowActionsCell = /*@__PURE__*/createReactComponent('modus-table-row-actions-cell'); -export const ModusTableRowActionsMenu = /*@__PURE__*/createReactComponent('modus-table-row-actions-menu'); -export const ModusTableToolbar = /*@__PURE__*/createReactComponent('modus-table-toolbar'); -export const ModusTabs = /*@__PURE__*/createReactComponent('modus-tabs'); -export const ModusTextInput = /*@__PURE__*/createReactComponent('modus-text-input'); -export const ModusTimePicker = /*@__PURE__*/createReactComponent('modus-time-picker'); -export const ModusToast = /*@__PURE__*/createReactComponent('modus-toast'); -export const ModusTooltip = /*@__PURE__*/createReactComponent('modus-tooltip'); -export const ModusTreeView = /*@__PURE__*/createReactComponent('modus-tree-view'); -export const ModusTreeViewItem = /*@__PURE__*/createReactComponent('modus-tree-view-item'); diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/createComponent.tsx b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/createComponent.tsx deleted file mode 100644 index 7c7415a29..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/createComponent.tsx +++ /dev/null @@ -1,106 +0,0 @@ -import React, { createElement } from 'react'; - -import { attachProps, camelToDashCase, createForwardRef, dashToPascalCase, isCoveredByReact, mergeRefs } from './utils'; - -export interface HTMLStencilElement extends HTMLElement { - componentOnReady(): Promise; -} - -interface StencilReactInternalProps extends React.HTMLAttributes { - forwardedRef: React.RefObject; - ref?: React.Ref; -} - -export const createReactComponent = < - PropType, - ElementType extends HTMLStencilElement, - ContextStateType = {}, - ExpandedPropsTypes = {} ->( - tagName: string, - ReactComponentContext?: React.Context, - manipulatePropsFunction?: ( - originalProps: StencilReactInternalProps, - propsToPass: any - ) => ExpandedPropsTypes, - defineCustomElement?: () => void -) => { - if (defineCustomElement !== undefined) { - defineCustomElement(); - } - - const displayName = dashToPascalCase(tagName); - const ReactComponent = class extends React.Component> { - componentEl!: ElementType; - - setComponentElRef = (element: ElementType) => { - this.componentEl = element; - }; - - constructor(props: StencilReactInternalProps) { - super(props); - } - - componentDidMount() { - this.componentDidUpdate(this.props); - } - - componentDidUpdate(prevProps: StencilReactInternalProps) { - attachProps(this.componentEl, this.props, prevProps); - } - - render() { - const { children, forwardedRef, style, className, ref, ...cProps } = this.props; - - let propsToPass = Object.keys(cProps).reduce((acc: any, name) => { - const value = (cProps as any)[name]; - - if (name.indexOf('on') === 0 && name[2] === name[2].toUpperCase()) { - const eventName = name.substring(2).toLowerCase(); - if (typeof document !== 'undefined' && isCoveredByReact(eventName)) { - acc[name] = value; - } - } else { - // we should only render strings, booleans, and numbers as attrs in html. - // objects, functions, arrays etc get synced via properties on mount. - const type = typeof value; - - if (type === 'string' || type === 'boolean' || type === 'number') { - acc[camelToDashCase(name)] = value; - } - } - return acc; - }, {} as ExpandedPropsTypes); - - if (manipulatePropsFunction) { - propsToPass = manipulatePropsFunction(this.props, propsToPass); - } - - const newProps: Omit, 'forwardedRef'> = { - ...propsToPass, - ref: mergeRefs(forwardedRef, this.setComponentElRef), - style, - }; - - /** - * We use createElement here instead of - * React.createElement to work around a - * bug in Vite (https://github.com/vitejs/vite/issues/6104). - * React.createElement causes all elements to be rendered - * as instead of the actual Web Component. - */ - return createElement(tagName, newProps, children); - } - - static get displayName() { - return displayName; - } - }; - - // If context was passed to createReactComponent then conditionally add it to the Component Class - if (ReactComponentContext) { - ReactComponent.contextType = ReactComponentContext; - } - - return createForwardRef(ReactComponent, displayName); -}; diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/createOverlayComponent.tsx b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/createOverlayComponent.tsx deleted file mode 100644 index 288c38dd5..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/createOverlayComponent.tsx +++ /dev/null @@ -1,142 +0,0 @@ -import React from 'react'; -import ReactDOM from 'react-dom'; - -import { OverlayEventDetail } from './interfaces'; -import { StencilReactForwardedRef, attachProps, dashToPascalCase, defineCustomElement, setRef } from './utils'; - -interface OverlayElement extends HTMLElement { - present: () => Promise; - dismiss: (data?: any, role?: string | undefined) => Promise; -} - -export interface ReactOverlayProps { - children?: React.ReactNode; - isOpen: boolean; - onDidDismiss?: (event: CustomEvent) => void; - onDidPresent?: (event: CustomEvent) => void; - onWillDismiss?: (event: CustomEvent) => void; - onWillPresent?: (event: CustomEvent) => void; -} - -export const createOverlayComponent = ( - tagName: string, - controller: { create: (options: any) => Promise }, - customElement?: any -) => { - defineCustomElement(tagName, customElement); - - const displayName = dashToPascalCase(tagName); - const didDismissEventName = `on${displayName}DidDismiss`; - const didPresentEventName = `on${displayName}DidPresent`; - const willDismissEventName = `on${displayName}WillDismiss`; - const willPresentEventName = `on${displayName}WillPresent`; - - type Props = OverlayComponent & - ReactOverlayProps & { - forwardedRef?: StencilReactForwardedRef; - }; - - let isDismissing = false; - - class Overlay extends React.Component { - overlay?: OverlayType; - el!: HTMLDivElement; - - constructor(props: Props) { - super(props); - if (typeof document !== 'undefined') { - this.el = document.createElement('div'); - } - this.handleDismiss = this.handleDismiss.bind(this); - } - - static get displayName() { - return displayName; - } - - componentDidMount() { - if (this.props.isOpen) { - this.present(); - } - } - - componentWillUnmount() { - if (this.overlay) { - this.overlay.dismiss(); - } - } - - handleDismiss(event: CustomEvent>) { - if (this.props.onDidDismiss) { - this.props.onDidDismiss(event); - } - setRef(this.props.forwardedRef, null); - } - - shouldComponentUpdate(nextProps: Props) { - // Check if the overlay component is about to dismiss - if (this.overlay && nextProps.isOpen !== this.props.isOpen && nextProps.isOpen === false) { - isDismissing = true; - } - - return true; - } - - async componentDidUpdate(prevProps: Props) { - if (this.overlay) { - attachProps(this.overlay, this.props, prevProps); - } - - if (prevProps.isOpen !== this.props.isOpen && this.props.isOpen === true) { - this.present(prevProps); - } - if (this.overlay && prevProps.isOpen !== this.props.isOpen && this.props.isOpen === false) { - await this.overlay.dismiss(); - isDismissing = false; - - /** - * Now that the overlay is dismissed - * we need to render again so that any - * inner components will be unmounted - */ - this.forceUpdate(); - } - } - - async present(prevProps?: Props) { - const { children, isOpen, onDidDismiss, onDidPresent, onWillDismiss, onWillPresent, ...cProps } = this.props; - const elementProps = { - ...cProps, - ref: this.props.forwardedRef, - [didDismissEventName]: this.handleDismiss, - [didPresentEventName]: (e: CustomEvent) => this.props.onDidPresent && this.props.onDidPresent(e), - [willDismissEventName]: (e: CustomEvent) => this.props.onWillDismiss && this.props.onWillDismiss(e), - [willPresentEventName]: (e: CustomEvent) => this.props.onWillPresent && this.props.onWillPresent(e), - }; - - this.overlay = await controller.create({ - ...elementProps, - component: this.el, - componentProps: {}, - }); - - setRef(this.props.forwardedRef, this.overlay); - attachProps(this.overlay, elementProps, prevProps); - - await this.overlay.present(); - } - - render() { - /** - * Continue to render the component even when - * overlay is dismissing otherwise component - * will be hidden before animation is done. - */ - return ReactDOM.createPortal(this.props.isOpen || isDismissing ? this.props.children : null, this.el); - } - } - - return React.forwardRef((props, ref) => { - return ; - }); -}; diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/index.ts b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/index.ts deleted file mode 100644 index 85e81ad19..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { createReactComponent } from './createComponent'; -export { createOverlayComponent } from './createOverlayComponent'; diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/interfaces.ts b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/interfaces.ts deleted file mode 100644 index 92e5389c8..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/interfaces.ts +++ /dev/null @@ -1,34 +0,0 @@ -// General types important to applications using stencil built components -export interface EventEmitter { - emit: (data?: T) => CustomEvent; -} - -export interface StyleReactProps { - class?: string; - className?: string; - style?: { [key: string]: any }; -} - -export interface OverlayEventDetail { - data?: T; - role?: string; -} - -export interface OverlayInterface { - el: HTMLElement; - animated: boolean; - keyboardClose: boolean; - overlayIndex: number; - presented: boolean; - - enterAnimation?: any; - leaveAnimation?: any; - - didPresent: EventEmitter; - willPresent: EventEmitter; - willDismiss: EventEmitter; - didDismiss: EventEmitter; - - present(): Promise; - dismiss(data?: any, role?: string): Promise; -} diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/attachProps.ts b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/attachProps.ts deleted file mode 100644 index 9a1825f54..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/attachProps.ts +++ /dev/null @@ -1,125 +0,0 @@ -import { camelToDashCase } from './case'; - -export const attachProps = (node: HTMLElement, newProps: any, oldProps: any = {}) => { - // some test frameworks don't render DOM elements, so we test here to make sure we are dealing with DOM first - if (node instanceof Element) { - // add any classes in className to the class list - const className = getClassName(node.classList, newProps, oldProps); - if (className !== '') { - node.className = className; - } - - Object.keys(newProps).forEach((name) => { - if ( - name === 'children' || - name === 'style' || - name === 'ref' || - name === 'class' || - name === 'className' || - name === 'forwardedRef' - ) { - return; - } - if (name.indexOf('on') === 0 && name[2] === name[2].toUpperCase()) { - const eventName = name.substring(2); - const eventNameLc = eventName[0].toLowerCase() + eventName.substring(1); - - if (!isCoveredByReact(eventNameLc)) { - syncEvent(node, eventNameLc, newProps[name]); - } - } else { - (node as any)[name] = newProps[name]; - const propType = typeof newProps[name]; - if (propType === 'string') { - node.setAttribute(camelToDashCase(name), newProps[name]); - } - } - }); - } -}; - -export const getClassName = (classList: DOMTokenList, newProps: any, oldProps: any) => { - const newClassProp: string = newProps.className || newProps.class; - const oldClassProp: string = oldProps.className || oldProps.class; - // map the classes to Maps for performance - const currentClasses = arrayToMap(classList); - const incomingPropClasses = arrayToMap(newClassProp ? newClassProp.split(' ') : []); - const oldPropClasses = arrayToMap(oldClassProp ? oldClassProp.split(' ') : []); - const finalClassNames: string[] = []; - // loop through each of the current classes on the component - // to see if it should be a part of the classNames added - currentClasses.forEach((currentClass) => { - if (incomingPropClasses.has(currentClass)) { - // add it as its already included in classnames coming in from newProps - finalClassNames.push(currentClass); - incomingPropClasses.delete(currentClass); - } else if (!oldPropClasses.has(currentClass)) { - // add it as it has NOT been removed by user - finalClassNames.push(currentClass); - } - }); - incomingPropClasses.forEach((s) => finalClassNames.push(s)); - return finalClassNames.join(' '); -}; - -/** - * Transforms a React event name to a browser event name. - */ -export const transformReactEventName = (eventNameSuffix: string) => { - switch (eventNameSuffix) { - case 'doubleclick': - return 'dblclick'; - } - return eventNameSuffix; -}; - -/** - * Checks if an event is supported in the current execution environment. - * @license Modernizr 3.0.0pre (Custom Build) | MIT - */ -export const isCoveredByReact = (eventNameSuffix: string) => { - if (typeof document === 'undefined') { - return true; - } else { - const eventName = 'on' + transformReactEventName(eventNameSuffix); - let isSupported = eventName in document; - - if (!isSupported) { - const element = document.createElement('div'); - element.setAttribute(eventName, 'return;'); - isSupported = typeof (element as any)[eventName] === 'function'; - } - - return isSupported; - } -}; - -export const syncEvent = ( - node: Element & { __events?: { [key: string]: ((e: Event) => any) | undefined } }, - eventName: string, - newEventHandler?: (e: Event) => any -) => { - const eventStore = node.__events || (node.__events = {}); - const oldEventHandler = eventStore[eventName]; - - // Remove old listener so they don't double up. - if (oldEventHandler) { - node.removeEventListener(eventName, oldEventHandler); - } - - // Bind new listener. - node.addEventListener( - eventName, - (eventStore[eventName] = function handler(e: Event) { - if (newEventHandler) { - newEventHandler.call(this, e); - } - }) - ); -}; - -const arrayToMap = (arr: string[] | DOMTokenList) => { - const map = new Map(); - (arr as string[]).forEach((s: string) => map.set(s, s)); - return map; -}; diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/case.ts b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/case.ts deleted file mode 100644 index 786689dc9..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/case.ts +++ /dev/null @@ -1,7 +0,0 @@ -export const dashToPascalCase = (str: string) => - str - .toLowerCase() - .split('-') - .map((segment) => segment.charAt(0).toUpperCase() + segment.slice(1)) - .join(''); -export const camelToDashCase = (str: string) => str.replace(/([A-Z])/g, (m: string) => `-${m[0].toLowerCase()}`); diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/dev.ts b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/dev.ts deleted file mode 100644 index cc6f9ed08..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/dev.ts +++ /dev/null @@ -1,14 +0,0 @@ -export const isDevMode = () => { - return process && process.env && process.env.NODE_ENV === 'development'; -}; - -const warnings: { [key: string]: boolean } = {}; - -export const deprecationWarning = (key: string, message: string) => { - if (isDevMode()) { - if (!warnings[key]) { - console.warn(message); - warnings[key] = true; - } - } -}; diff --git a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/index.tsx b/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/index.tsx deleted file mode 100644 index a66bd02de..000000000 --- a/react-workspace/react-17/src/components/stencil-generated/react-component-lib/utils/index.tsx +++ /dev/null @@ -1,50 +0,0 @@ -import React from 'react'; - -import type { StyleReactProps } from '../interfaces'; - -export type StencilReactExternalProps = PropType & - Omit, 'style'> & - StyleReactProps; - -// This will be replaced with React.ForwardedRef when react-output-target is upgraded to React v17 -export type StencilReactForwardedRef = ((instance: T | null) => void) | React.MutableRefObject | null; - -export const setRef = (ref: StencilReactForwardedRef | React.Ref | undefined, value: any) => { - if (typeof ref === 'function') { - ref(value); - } else if (ref != null) { - // Cast as a MutableRef so we can assign current - (ref as React.MutableRefObject).current = value; - } -}; - -export const mergeRefs = ( - ...refs: (StencilReactForwardedRef | React.Ref | undefined)[] -): React.RefCallback => { - return (value: any) => { - refs.forEach((ref) => { - setRef(ref, value); - }); - }; -}; - -export const createForwardRef = (ReactComponent: any, displayName: string) => { - const forwardRef = ( - props: StencilReactExternalProps, - ref: StencilReactForwardedRef - ) => { - return ; - }; - forwardRef.displayName = displayName; - - return React.forwardRef(forwardRef); -}; - -export const defineCustomElement = (tagName: string, customElement: any) => { - if (customElement !== undefined && typeof customElements !== 'undefined' && !customElements.get(tagName)) { - customElements.define(tagName, customElement); - } -}; - -export * from './attachProps'; -export * from './case'; diff --git a/react-workspace/react-18/package-lock.json b/react-workspace/react-18/package-lock.json index ee59c5ba7..d93d0581f 100644 --- a/react-workspace/react-18/package-lock.json +++ b/react-workspace/react-18/package-lock.json @@ -1,15 +1,15 @@ { "name": "@trimble-oss/modus-react-components", - "version": "0.22.0-react18", + "version": "0.27.0-react18", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@trimble-oss/modus-react-components", - "version": "0.22.0-react18", + "version": "0.27.0-react18", "license": "MIT", "dependencies": { - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "devDependencies": { "@types/jest": "23.3.14", @@ -1066,9 +1066,9 @@ } }, "node_modules/@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "dependencies": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", @@ -4968,9 +4968,9 @@ "integrity": "sha512-69WEY1PaZROaGYUrseng4/4sMYnRGhDe1vM6888CnWekGz/wuCnvqwOoOuKGYivnaiI4BVmZq4WKWhvahyj3/g==" }, "@trimble-oss/modus-web-components": { - "version": "0.22.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.22.0.tgz", - "integrity": "sha512-+c0Niz1pcPPx6DaQ7vw0c4cuaVtYG8CWWXNkH2U8z0u77q6YKZ1pKtmnAvXb9uUYcwg0ChIohBsSdsX/IqYSjQ==", + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-web-components/-/modus-web-components-0.27.0.tgz", + "integrity": "sha512-X527beFYj0FVdV1jQfc19z3Lczeg2D8CDaTgA647cIbC91pWDKXZclJ6YpU4PMjzRxUmFFFOPQR0Uj5iWsiPSQ==", "requires": { "@popperjs/core": "^2.11.8", "@stencil/core": "^4.12.4", diff --git a/react-workspace/react-18/package.json b/react-workspace/react-18/package.json index ac5cd6b24..df3085aaf 100644 --- a/react-workspace/react-18/package.json +++ b/react-workspace/react-18/package.json @@ -1,6 +1,6 @@ { "name": "@trimble-oss/modus-react-components", - "version": "0.22.0-react18", + "version": "0.27.0-react18", "description": "Trimble Modus React Component Library", "homepage": "https://modus-web-components.trimble.com/", "bugs": { @@ -33,7 +33,7 @@ ] }, "dependencies": { - "@trimble-oss/modus-web-components": "0.22.0" + "@trimble-oss/modus-web-components": "0.27.0" }, "devDependencies": { "@types/jest": "23.3.14", diff --git a/react-workspace/react-18/src/components/stencil-generated/index.ts b/react-workspace/react-18/src/components/stencil-generated/index.ts deleted file mode 100644 index 460273102..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/index.ts +++ /dev/null @@ -1,66 +0,0 @@ -/* eslint-disable */ -/* tslint:disable */ -/* auto-generated react proxies */ -import { createReactComponent } from './react-component-lib'; - -import type { JSX } from '@trimble-oss/modus-web-components'; - -import { defineCustomElements } from '@trimble-oss/modus-web-components/loader'; - -defineCustomElements(); -export const ModusAccordion = /*@__PURE__*/createReactComponent('modus-accordion'); -export const ModusAccordionItem = /*@__PURE__*/createReactComponent('modus-accordion-item'); -export const ModusActionBar = /*@__PURE__*/createReactComponent('modus-action-bar'); -export const ModusAlert = /*@__PURE__*/createReactComponent('modus-alert'); -export const ModusAutocomplete = /*@__PURE__*/createReactComponent('modus-autocomplete'); -export const ModusBadge = /*@__PURE__*/createReactComponent('modus-badge'); -export const ModusBreadcrumb = /*@__PURE__*/createReactComponent('modus-breadcrumb'); -export const ModusButton = /*@__PURE__*/createReactComponent('modus-button'); -export const ModusCard = /*@__PURE__*/createReactComponent('modus-card'); -export const ModusCheckbox = /*@__PURE__*/createReactComponent('modus-checkbox'); -export const ModusChip = /*@__PURE__*/createReactComponent('modus-chip'); -export const ModusDataTable = /*@__PURE__*/createReactComponent('modus-data-table'); -export const ModusDateInput = /*@__PURE__*/createReactComponent('modus-date-input'); -export const ModusDatePicker = /*@__PURE__*/createReactComponent('modus-date-picker'); -export const ModusDropdown = /*@__PURE__*/createReactComponent('modus-dropdown'); -export const ModusFileDropzone = /*@__PURE__*/createReactComponent('modus-file-dropzone'); -export const ModusIcon = /*@__PURE__*/createReactComponent('modus-icon'); -export const ModusList = /*@__PURE__*/createReactComponent('modus-list'); -export const ModusListItem = /*@__PURE__*/createReactComponent('modus-list-item'); -export const ModusMessage = /*@__PURE__*/createReactComponent('modus-message'); -export const ModusModal = /*@__PURE__*/createReactComponent('modus-modal'); -export const ModusNavbar = /*@__PURE__*/createReactComponent('modus-navbar'); -export const ModusNavbarAppsMenu = /*@__PURE__*/createReactComponent('modus-navbar-apps-menu'); -export const ModusNavbarButtonMenu = /*@__PURE__*/createReactComponent('modus-navbar-button-menu'); -export const ModusNavbarMainMenu = /*@__PURE__*/createReactComponent('modus-navbar-main-menu'); -export const ModusNavbarNotificationsMenu = /*@__PURE__*/createReactComponent('modus-navbar-notifications-menu'); -export const ModusNavbarProfileMenu = /*@__PURE__*/createReactComponent('modus-navbar-profile-menu'); -export const ModusNavbarSearchOverlay = /*@__PURE__*/createReactComponent('modus-navbar-search-overlay'); -export const ModusNumberInput = /*@__PURE__*/createReactComponent('modus-number-input'); -export const ModusPagination = /*@__PURE__*/createReactComponent('modus-pagination'); -export const ModusProgressBar = /*@__PURE__*/createReactComponent('modus-progress-bar'); -export const ModusRadioGroup = /*@__PURE__*/createReactComponent('modus-radio-group'); -export const ModusSelect = /*@__PURE__*/createReactComponent('modus-select'); -export const ModusSentimentScale = /*@__PURE__*/createReactComponent('modus-sentiment-scale'); -export const ModusSideNavigation = /*@__PURE__*/createReactComponent('modus-side-navigation'); -export const ModusSideNavigationItem = /*@__PURE__*/createReactComponent('modus-side-navigation-item'); -export const ModusSlider = /*@__PURE__*/createReactComponent('modus-slider'); -export const ModusSpinner = /*@__PURE__*/createReactComponent('modus-spinner'); -export const ModusSwitch = /*@__PURE__*/createReactComponent('modus-switch'); -export const ModusTable = /*@__PURE__*/createReactComponent('modus-table'); -export const ModusTableCellEditor = /*@__PURE__*/createReactComponent('modus-table-cell-editor'); -export const ModusTableCellMain = /*@__PURE__*/createReactComponent('modus-table-cell-main'); -export const ModusTableColumnsVisibility = /*@__PURE__*/createReactComponent('modus-table-columns-visibility'); -export const ModusTableDropdownMenu = /*@__PURE__*/createReactComponent('modus-table-dropdown-menu'); -export const ModusTableFillerColumn = /*@__PURE__*/createReactComponent('modus-table-filler-column'); -export const ModusTableRowActions = /*@__PURE__*/createReactComponent('modus-table-row-actions'); -export const ModusTableRowActionsCell = /*@__PURE__*/createReactComponent('modus-table-row-actions-cell'); -export const ModusTableRowActionsMenu = /*@__PURE__*/createReactComponent('modus-table-row-actions-menu'); -export const ModusTableToolbar = /*@__PURE__*/createReactComponent('modus-table-toolbar'); -export const ModusTabs = /*@__PURE__*/createReactComponent('modus-tabs'); -export const ModusTextInput = /*@__PURE__*/createReactComponent('modus-text-input'); -export const ModusTimePicker = /*@__PURE__*/createReactComponent('modus-time-picker'); -export const ModusToast = /*@__PURE__*/createReactComponent('modus-toast'); -export const ModusTooltip = /*@__PURE__*/createReactComponent('modus-tooltip'); -export const ModusTreeView = /*@__PURE__*/createReactComponent('modus-tree-view'); -export const ModusTreeViewItem = /*@__PURE__*/createReactComponent('modus-tree-view-item'); diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/createComponent.tsx b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/createComponent.tsx deleted file mode 100644 index 7c7415a29..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/createComponent.tsx +++ /dev/null @@ -1,106 +0,0 @@ -import React, { createElement } from 'react'; - -import { attachProps, camelToDashCase, createForwardRef, dashToPascalCase, isCoveredByReact, mergeRefs } from './utils'; - -export interface HTMLStencilElement extends HTMLElement { - componentOnReady(): Promise; -} - -interface StencilReactInternalProps extends React.HTMLAttributes { - forwardedRef: React.RefObject; - ref?: React.Ref; -} - -export const createReactComponent = < - PropType, - ElementType extends HTMLStencilElement, - ContextStateType = {}, - ExpandedPropsTypes = {} ->( - tagName: string, - ReactComponentContext?: React.Context, - manipulatePropsFunction?: ( - originalProps: StencilReactInternalProps, - propsToPass: any - ) => ExpandedPropsTypes, - defineCustomElement?: () => void -) => { - if (defineCustomElement !== undefined) { - defineCustomElement(); - } - - const displayName = dashToPascalCase(tagName); - const ReactComponent = class extends React.Component> { - componentEl!: ElementType; - - setComponentElRef = (element: ElementType) => { - this.componentEl = element; - }; - - constructor(props: StencilReactInternalProps) { - super(props); - } - - componentDidMount() { - this.componentDidUpdate(this.props); - } - - componentDidUpdate(prevProps: StencilReactInternalProps) { - attachProps(this.componentEl, this.props, prevProps); - } - - render() { - const { children, forwardedRef, style, className, ref, ...cProps } = this.props; - - let propsToPass = Object.keys(cProps).reduce((acc: any, name) => { - const value = (cProps as any)[name]; - - if (name.indexOf('on') === 0 && name[2] === name[2].toUpperCase()) { - const eventName = name.substring(2).toLowerCase(); - if (typeof document !== 'undefined' && isCoveredByReact(eventName)) { - acc[name] = value; - } - } else { - // we should only render strings, booleans, and numbers as attrs in html. - // objects, functions, arrays etc get synced via properties on mount. - const type = typeof value; - - if (type === 'string' || type === 'boolean' || type === 'number') { - acc[camelToDashCase(name)] = value; - } - } - return acc; - }, {} as ExpandedPropsTypes); - - if (manipulatePropsFunction) { - propsToPass = manipulatePropsFunction(this.props, propsToPass); - } - - const newProps: Omit, 'forwardedRef'> = { - ...propsToPass, - ref: mergeRefs(forwardedRef, this.setComponentElRef), - style, - }; - - /** - * We use createElement here instead of - * React.createElement to work around a - * bug in Vite (https://github.com/vitejs/vite/issues/6104). - * React.createElement causes all elements to be rendered - * as instead of the actual Web Component. - */ - return createElement(tagName, newProps, children); - } - - static get displayName() { - return displayName; - } - }; - - // If context was passed to createReactComponent then conditionally add it to the Component Class - if (ReactComponentContext) { - ReactComponent.contextType = ReactComponentContext; - } - - return createForwardRef(ReactComponent, displayName); -}; diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/createOverlayComponent.tsx b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/createOverlayComponent.tsx deleted file mode 100644 index 288c38dd5..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/createOverlayComponent.tsx +++ /dev/null @@ -1,142 +0,0 @@ -import React from 'react'; -import ReactDOM from 'react-dom'; - -import { OverlayEventDetail } from './interfaces'; -import { StencilReactForwardedRef, attachProps, dashToPascalCase, defineCustomElement, setRef } from './utils'; - -interface OverlayElement extends HTMLElement { - present: () => Promise; - dismiss: (data?: any, role?: string | undefined) => Promise; -} - -export interface ReactOverlayProps { - children?: React.ReactNode; - isOpen: boolean; - onDidDismiss?: (event: CustomEvent) => void; - onDidPresent?: (event: CustomEvent) => void; - onWillDismiss?: (event: CustomEvent) => void; - onWillPresent?: (event: CustomEvent) => void; -} - -export const createOverlayComponent = ( - tagName: string, - controller: { create: (options: any) => Promise }, - customElement?: any -) => { - defineCustomElement(tagName, customElement); - - const displayName = dashToPascalCase(tagName); - const didDismissEventName = `on${displayName}DidDismiss`; - const didPresentEventName = `on${displayName}DidPresent`; - const willDismissEventName = `on${displayName}WillDismiss`; - const willPresentEventName = `on${displayName}WillPresent`; - - type Props = OverlayComponent & - ReactOverlayProps & { - forwardedRef?: StencilReactForwardedRef; - }; - - let isDismissing = false; - - class Overlay extends React.Component { - overlay?: OverlayType; - el!: HTMLDivElement; - - constructor(props: Props) { - super(props); - if (typeof document !== 'undefined') { - this.el = document.createElement('div'); - } - this.handleDismiss = this.handleDismiss.bind(this); - } - - static get displayName() { - return displayName; - } - - componentDidMount() { - if (this.props.isOpen) { - this.present(); - } - } - - componentWillUnmount() { - if (this.overlay) { - this.overlay.dismiss(); - } - } - - handleDismiss(event: CustomEvent>) { - if (this.props.onDidDismiss) { - this.props.onDidDismiss(event); - } - setRef(this.props.forwardedRef, null); - } - - shouldComponentUpdate(nextProps: Props) { - // Check if the overlay component is about to dismiss - if (this.overlay && nextProps.isOpen !== this.props.isOpen && nextProps.isOpen === false) { - isDismissing = true; - } - - return true; - } - - async componentDidUpdate(prevProps: Props) { - if (this.overlay) { - attachProps(this.overlay, this.props, prevProps); - } - - if (prevProps.isOpen !== this.props.isOpen && this.props.isOpen === true) { - this.present(prevProps); - } - if (this.overlay && prevProps.isOpen !== this.props.isOpen && this.props.isOpen === false) { - await this.overlay.dismiss(); - isDismissing = false; - - /** - * Now that the overlay is dismissed - * we need to render again so that any - * inner components will be unmounted - */ - this.forceUpdate(); - } - } - - async present(prevProps?: Props) { - const { children, isOpen, onDidDismiss, onDidPresent, onWillDismiss, onWillPresent, ...cProps } = this.props; - const elementProps = { - ...cProps, - ref: this.props.forwardedRef, - [didDismissEventName]: this.handleDismiss, - [didPresentEventName]: (e: CustomEvent) => this.props.onDidPresent && this.props.onDidPresent(e), - [willDismissEventName]: (e: CustomEvent) => this.props.onWillDismiss && this.props.onWillDismiss(e), - [willPresentEventName]: (e: CustomEvent) => this.props.onWillPresent && this.props.onWillPresent(e), - }; - - this.overlay = await controller.create({ - ...elementProps, - component: this.el, - componentProps: {}, - }); - - setRef(this.props.forwardedRef, this.overlay); - attachProps(this.overlay, elementProps, prevProps); - - await this.overlay.present(); - } - - render() { - /** - * Continue to render the component even when - * overlay is dismissing otherwise component - * will be hidden before animation is done. - */ - return ReactDOM.createPortal(this.props.isOpen || isDismissing ? this.props.children : null, this.el); - } - } - - return React.forwardRef((props, ref) => { - return ; - }); -}; diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/index.ts b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/index.ts deleted file mode 100644 index 85e81ad19..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { createReactComponent } from './createComponent'; -export { createOverlayComponent } from './createOverlayComponent'; diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/interfaces.ts b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/interfaces.ts deleted file mode 100644 index 92e5389c8..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/interfaces.ts +++ /dev/null @@ -1,34 +0,0 @@ -// General types important to applications using stencil built components -export interface EventEmitter { - emit: (data?: T) => CustomEvent; -} - -export interface StyleReactProps { - class?: string; - className?: string; - style?: { [key: string]: any }; -} - -export interface OverlayEventDetail { - data?: T; - role?: string; -} - -export interface OverlayInterface { - el: HTMLElement; - animated: boolean; - keyboardClose: boolean; - overlayIndex: number; - presented: boolean; - - enterAnimation?: any; - leaveAnimation?: any; - - didPresent: EventEmitter; - willPresent: EventEmitter; - willDismiss: EventEmitter; - didDismiss: EventEmitter; - - present(): Promise; - dismiss(data?: any, role?: string): Promise; -} diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/attachProps.ts b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/attachProps.ts deleted file mode 100644 index 9a1825f54..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/attachProps.ts +++ /dev/null @@ -1,125 +0,0 @@ -import { camelToDashCase } from './case'; - -export const attachProps = (node: HTMLElement, newProps: any, oldProps: any = {}) => { - // some test frameworks don't render DOM elements, so we test here to make sure we are dealing with DOM first - if (node instanceof Element) { - // add any classes in className to the class list - const className = getClassName(node.classList, newProps, oldProps); - if (className !== '') { - node.className = className; - } - - Object.keys(newProps).forEach((name) => { - if ( - name === 'children' || - name === 'style' || - name === 'ref' || - name === 'class' || - name === 'className' || - name === 'forwardedRef' - ) { - return; - } - if (name.indexOf('on') === 0 && name[2] === name[2].toUpperCase()) { - const eventName = name.substring(2); - const eventNameLc = eventName[0].toLowerCase() + eventName.substring(1); - - if (!isCoveredByReact(eventNameLc)) { - syncEvent(node, eventNameLc, newProps[name]); - } - } else { - (node as any)[name] = newProps[name]; - const propType = typeof newProps[name]; - if (propType === 'string') { - node.setAttribute(camelToDashCase(name), newProps[name]); - } - } - }); - } -}; - -export const getClassName = (classList: DOMTokenList, newProps: any, oldProps: any) => { - const newClassProp: string = newProps.className || newProps.class; - const oldClassProp: string = oldProps.className || oldProps.class; - // map the classes to Maps for performance - const currentClasses = arrayToMap(classList); - const incomingPropClasses = arrayToMap(newClassProp ? newClassProp.split(' ') : []); - const oldPropClasses = arrayToMap(oldClassProp ? oldClassProp.split(' ') : []); - const finalClassNames: string[] = []; - // loop through each of the current classes on the component - // to see if it should be a part of the classNames added - currentClasses.forEach((currentClass) => { - if (incomingPropClasses.has(currentClass)) { - // add it as its already included in classnames coming in from newProps - finalClassNames.push(currentClass); - incomingPropClasses.delete(currentClass); - } else if (!oldPropClasses.has(currentClass)) { - // add it as it has NOT been removed by user - finalClassNames.push(currentClass); - } - }); - incomingPropClasses.forEach((s) => finalClassNames.push(s)); - return finalClassNames.join(' '); -}; - -/** - * Transforms a React event name to a browser event name. - */ -export const transformReactEventName = (eventNameSuffix: string) => { - switch (eventNameSuffix) { - case 'doubleclick': - return 'dblclick'; - } - return eventNameSuffix; -}; - -/** - * Checks if an event is supported in the current execution environment. - * @license Modernizr 3.0.0pre (Custom Build) | MIT - */ -export const isCoveredByReact = (eventNameSuffix: string) => { - if (typeof document === 'undefined') { - return true; - } else { - const eventName = 'on' + transformReactEventName(eventNameSuffix); - let isSupported = eventName in document; - - if (!isSupported) { - const element = document.createElement('div'); - element.setAttribute(eventName, 'return;'); - isSupported = typeof (element as any)[eventName] === 'function'; - } - - return isSupported; - } -}; - -export const syncEvent = ( - node: Element & { __events?: { [key: string]: ((e: Event) => any) | undefined } }, - eventName: string, - newEventHandler?: (e: Event) => any -) => { - const eventStore = node.__events || (node.__events = {}); - const oldEventHandler = eventStore[eventName]; - - // Remove old listener so they don't double up. - if (oldEventHandler) { - node.removeEventListener(eventName, oldEventHandler); - } - - // Bind new listener. - node.addEventListener( - eventName, - (eventStore[eventName] = function handler(e: Event) { - if (newEventHandler) { - newEventHandler.call(this, e); - } - }) - ); -}; - -const arrayToMap = (arr: string[] | DOMTokenList) => { - const map = new Map(); - (arr as string[]).forEach((s: string) => map.set(s, s)); - return map; -}; diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/case.ts b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/case.ts deleted file mode 100644 index 786689dc9..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/case.ts +++ /dev/null @@ -1,7 +0,0 @@ -export const dashToPascalCase = (str: string) => - str - .toLowerCase() - .split('-') - .map((segment) => segment.charAt(0).toUpperCase() + segment.slice(1)) - .join(''); -export const camelToDashCase = (str: string) => str.replace(/([A-Z])/g, (m: string) => `-${m[0].toLowerCase()}`); diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/dev.ts b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/dev.ts deleted file mode 100644 index cc6f9ed08..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/dev.ts +++ /dev/null @@ -1,14 +0,0 @@ -export const isDevMode = () => { - return process && process.env && process.env.NODE_ENV === 'development'; -}; - -const warnings: { [key: string]: boolean } = {}; - -export const deprecationWarning = (key: string, message: string) => { - if (isDevMode()) { - if (!warnings[key]) { - console.warn(message); - warnings[key] = true; - } - } -}; diff --git a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/index.tsx b/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/index.tsx deleted file mode 100644 index a66bd02de..000000000 --- a/react-workspace/react-18/src/components/stencil-generated/react-component-lib/utils/index.tsx +++ /dev/null @@ -1,50 +0,0 @@ -import React from 'react'; - -import type { StyleReactProps } from '../interfaces'; - -export type StencilReactExternalProps = PropType & - Omit, 'style'> & - StyleReactProps; - -// This will be replaced with React.ForwardedRef when react-output-target is upgraded to React v17 -export type StencilReactForwardedRef = ((instance: T | null) => void) | React.MutableRefObject | null; - -export const setRef = (ref: StencilReactForwardedRef | React.Ref | undefined, value: any) => { - if (typeof ref === 'function') { - ref(value); - } else if (ref != null) { - // Cast as a MutableRef so we can assign current - (ref as React.MutableRefObject).current = value; - } -}; - -export const mergeRefs = ( - ...refs: (StencilReactForwardedRef | React.Ref | undefined)[] -): React.RefCallback => { - return (value: any) => { - refs.forEach((ref) => { - setRef(ref, value); - }); - }; -}; - -export const createForwardRef = (ReactComponent: any, displayName: string) => { - const forwardRef = ( - props: StencilReactExternalProps, - ref: StencilReactForwardedRef - ) => { - return ; - }; - forwardRef.displayName = displayName; - - return React.forwardRef(forwardRef); -}; - -export const defineCustomElement = (tagName: string, customElement: any) => { - if (customElement !== undefined && typeof customElements !== 'undefined' && !customElements.get(tagName)) { - customElements.define(tagName, customElement); - } -}; - -export * from './attachProps'; -export * from './case'; diff --git a/react-workspace/test-react-v17/package-lock.json b/react-workspace/test-react-v17/package-lock.json index 00c64151d..6d76cbfd2 100644 --- a/react-workspace/test-react-v17/package-lock.json +++ b/react-workspace/test-react-v17/package-lock.json @@ -5530,13 +5530,13 @@ "dev": true }, "node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", "dev": true, "dependencies": { "bytes": "3.1.2", - "content-type": "~1.0.4", + "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", "destroy": "1.2.0", @@ -5544,7 +5544,7 @@ "iconv-lite": "0.4.24", "on-finished": "2.4.1", "qs": "6.11.0", - "raw-body": "2.5.1", + "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" }, @@ -6127,9 +6127,9 @@ "dev": true }, "node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true, "engines": { "node": ">= 0.6" @@ -8090,17 +8090,17 @@ } }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -15047,9 +15047,9 @@ } }, "node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", "dev": true, "dependencies": { "bytes": "3.1.2", @@ -22627,13 +22627,13 @@ "dev": true }, "body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", "dev": true, "requires": { "bytes": "3.1.2", - "content-type": "~1.0.4", + "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", "destroy": "1.2.0", @@ -22641,7 +22641,7 @@ "iconv-lite": "0.4.24", "on-finished": "2.4.1", "qs": "6.11.0", - "raw-body": "2.5.1", + "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" }, @@ -23089,9 +23089,9 @@ "dev": true }, "cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "dev": true }, "cookie-signature": { @@ -24529,17 +24529,17 @@ } }, "express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dev": true, "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -29520,9 +29520,9 @@ "dev": true }, "raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", "dev": true, "requires": { "bytes": "3.1.2", diff --git a/react-workspace/test-react-v18/package-lock.json b/react-workspace/test-react-v18/package-lock.json index d01d32ccc..9a7c6f40c 100644 --- a/react-workspace/test-react-v18/package-lock.json +++ b/react-workspace/test-react-v18/package-lock.json @@ -5435,12 +5435,12 @@ "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==" }, "node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", "dependencies": { "bytes": "3.1.2", - "content-type": "~1.0.4", + "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", "destroy": "1.2.0", @@ -5448,7 +5448,7 @@ "iconv-lite": "0.4.24", "on-finished": "2.4.1", "qs": "6.11.0", - "raw-body": "2.5.1", + "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" }, @@ -5974,9 +5974,9 @@ "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==" }, "node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "engines": { "node": ">= 0.6" } @@ -7848,16 +7848,16 @@ } }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -14192,9 +14192,9 @@ } }, "node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", "dependencies": { "bytes": "3.1.2", "http-errors": "2.0.0", @@ -21111,12 +21111,12 @@ "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==" }, "body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", "requires": { "bytes": "3.1.2", - "content-type": "~1.0.4", + "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", "destroy": "1.2.0", @@ -21124,7 +21124,7 @@ "iconv-lite": "0.4.24", "on-finished": "2.4.1", "qs": "6.11.0", - "raw-body": "2.5.1", + "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" }, @@ -21515,9 +21515,9 @@ "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==" }, "cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==" + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==" }, "cookie-signature": { "version": "1.0.6", @@ -22851,16 +22851,16 @@ } }, "express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -27240,9 +27240,9 @@ "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==" }, "raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", "requires": { "bytes": "3.1.2", "http-errors": "2.0.0", diff --git a/react-workspace/test-web-components/package-lock.json b/react-workspace/test-web-components/package-lock.json index e35796055..baca69bdf 100644 --- a/react-workspace/test-web-components/package-lock.json +++ b/react-workspace/test-web-components/package-lock.json @@ -5430,12 +5430,12 @@ "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==" }, "node_modules/body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", "dependencies": { "bytes": "3.1.2", - "content-type": "~1.0.4", + "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", "destroy": "1.2.0", @@ -5443,7 +5443,7 @@ "iconv-lite": "0.4.24", "on-finished": "2.4.1", "qs": "6.11.0", - "raw-body": "2.5.1", + "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" }, @@ -5969,9 +5969,9 @@ "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==" }, "node_modules/cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==", "engines": { "node": ">= 0.6" } @@ -7822,16 +7822,16 @@ } }, "node_modules/express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -14270,9 +14270,9 @@ } }, "node_modules/raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", "dependencies": { "bytes": "3.1.2", "http-errors": "2.0.0", @@ -21378,12 +21378,12 @@ "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==" }, "body-parser": { - "version": "1.20.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", - "integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==", + "version": "1.20.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", + "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", "requires": { "bytes": "3.1.2", - "content-type": "~1.0.4", + "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", "destroy": "1.2.0", @@ -21391,7 +21391,7 @@ "iconv-lite": "0.4.24", "on-finished": "2.4.1", "qs": "6.11.0", - "raw-body": "2.5.1", + "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" }, @@ -21782,9 +21782,9 @@ "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==" }, "cookie": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", - "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==" + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz", + "integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==" }, "cookie-signature": { "version": "1.0.6", @@ -23109,16 +23109,16 @@ } }, "express": { - "version": "4.18.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", - "integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==", + "version": "4.19.2", + "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", + "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.1", + "body-parser": "1.20.2", "content-disposition": "0.5.4", "content-type": "~1.0.4", - "cookie": "0.5.0", + "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", @@ -27576,9 +27576,9 @@ "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==" }, "raw-body": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz", - "integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==", + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", + "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", "requires": { "bytes": "3.1.2", "http-errors": "2.0.0", diff --git a/stencil-workspace/.eslintrc.js b/stencil-workspace/.eslintrc.js index 509a89e49..6b1ee9e97 100644 --- a/stencil-workspace/.eslintrc.js +++ b/stencil-workspace/.eslintrc.js @@ -14,5 +14,6 @@ module.exports = { rules: { '@typescript-eslint/ban-ts-comment': ['error', { 'ts-ignore': 'allow-with-description' }], 'jsx-quotes': ['error', 'prefer-double'], + 'no-console': 1, }, }; diff --git a/stencil-workspace/package-lock.json b/stencil-workspace/package-lock.json index 7771b0f3f..58103a220 100644 --- a/stencil-workspace/package-lock.json +++ b/stencil-workspace/package-lock.json @@ -1,12 +1,12 @@ { "name": "@trimble-oss/modus-web-components", - "version": "0.23.0", + "version": "0.27.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@trimble-oss/modus-web-components", - "version": "0.23.0", + "version": "0.27.0", "license": "MIT", "dependencies": { "@popperjs/core": "^2.11.8", @@ -18,7 +18,7 @@ "@stencil/postcss": "^2.1.0", "@stencil/react-output-target": "^0.5.3", "@stencil/sass": "^3.0.10", - "@trimble-oss/modus-icons": "1.11.0", + "@trimble-oss/modus-icons": "1.13.1", "@types/jest": "^27.5.1", "@typescript-eslint/eslint-plugin": "^5.59.0", "@typescript-eslint/parser": "^5.58.0", @@ -1524,9 +1524,9 @@ } }, "node_modules/@trimble-oss/modus-icons": { - "version": "1.11.0", - "resolved": "https://registry.npmjs.org/@trimble-oss/modus-icons/-/modus-icons-1.11.0.tgz", - "integrity": "sha512-gA9YDNAOrooaT9UvcNKLF/aiIn1rCFCbekneMX9FkuAmJ9GPBJ8vt5CK2d58LvKLI8+qBqtw+ww07YAarH5eHQ==", + "version": "1.13.1", + "resolved": "https://registry.npmjs.org/@trimble-oss/modus-icons/-/modus-icons-1.13.1.tgz", + "integrity": "sha512-z6qgOMB69LM0/zlQyBQnmFrn0JujXxUx1/GqemS0GVViVjk9vmQYT6xXGySqelrs8Snm2byLe+5CQoABWzHeZQ==", "dev": true }, "node_modules/@types/babel__core": { diff --git a/stencil-workspace/package.json b/stencil-workspace/package.json index 0183418f2..870354110 100644 --- a/stencil-workspace/package.json +++ b/stencil-workspace/package.json @@ -1,6 +1,6 @@ { "name": "@trimble-oss/modus-web-components", - "version": "0.23.0", + "version": "0.27.0", "description": "Trimble Modus Web Component Library", "homepage": "https://modus-web-components.trimble.com/", "bugs": { @@ -32,7 +32,8 @@ "generate": "stencil generate", "lint": "npm run lint-js && npm run lint-css && npm run prettier", "lint-js": "eslint \"src/**\" \"storybook/**/*.stories.tsx\"", - "lint-css": "stylelint \"src/**/*.scss\" --fix", + "lint-css": "stylelint \"src/**/*.scss\"", + "lint-css-fix": "stylelint \"src/**/*.scss\" --fix", "prettier": "prettier --write \"storybook/stories/**/*.*\" \"src/**/*.*\" --config ../.prettierrc.json --ignore-path ../.prettierignore", "full": "npm ci && npm run lint && npm run build && npm run test && npm run ci-storybook", "ci-storybook": "cd storybook && npm ci && npm run build-storybook", @@ -49,7 +50,7 @@ "@stencil/postcss": "^2.1.0", "@stencil/react-output-target": "^0.5.3", "@stencil/sass": "^3.0.10", - "@trimble-oss/modus-icons": "1.11.0", + "@trimble-oss/modus-icons": "1.13.1", "@types/jest": "^27.5.1", "@typescript-eslint/eslint-plugin": "^5.59.0", "@typescript-eslint/parser": "^5.58.0", diff --git a/stencil-workspace/src/components.d.ts b/stencil-workspace/src/components.d.ts index 9f6967fac..c6e65b9c3 100644 --- a/stencil-workspace/src/components.d.ts +++ b/stencil-workspace/src/components.d.ts @@ -9,6 +9,8 @@ import { ModusActionBarOptions } from "./components/modus-action-bar/modus-actio import { ModusAutocompleteOption } from "./components/modus-autocomplete/modus-autocomplete"; import { BadgeProperties } from "./components/modus-badge/modus-badge"; import { Crumb } from "./components/modus-breadcrumb/modus-breadcrumb"; +import { ButtonColor, ButtonSize, ButtonStyle, ButtonType } from "./components/modus-button/modus-button.models"; +import { ButtonGroupSelectionType } from "./components/modus-button-group/modus-button-group.models"; import { ModusDataTableCellLink, ModusDataTableDisplayOptions, ModusDataTableRowAction, ModusDataTableRowActionClickEvent, ModusDataTableSelectionOptions, ModusDataTableSortEvent, ModusDataTableSortOptions, TCell, TColumn, TRow } from "./components/modus-data-table/modus-data-table.models"; import { ModusDateInputEventDetails, ModusDateInputType } from "./components/modus-date-input/utils/modus-date-input.models"; import { ModusIconName } from "./icons/ModusIconUtilities"; @@ -30,6 +32,8 @@ export { ModusActionBarOptions } from "./components/modus-action-bar/modus-actio export { ModusAutocompleteOption } from "./components/modus-autocomplete/modus-autocomplete"; export { BadgeProperties } from "./components/modus-badge/modus-badge"; export { Crumb } from "./components/modus-breadcrumb/modus-breadcrumb"; +export { ButtonColor, ButtonSize, ButtonStyle, ButtonType } from "./components/modus-button/modus-button.models"; +export { ButtonGroupSelectionType } from "./components/modus-button-group/modus-button-group.models"; export { ModusDataTableCellLink, ModusDataTableDisplayOptions, ModusDataTableRowAction, ModusDataTableRowActionClickEvent, ModusDataTableSelectionOptions, ModusDataTableSortEvent, ModusDataTableSortOptions, TCell, TColumn, TRow } from "./components/modus-data-table/modus-data-table.models"; export { ModusDateInputEventDetails, ModusDateInputType } from "./components/modus-date-input/utils/modus-date-input.models"; export { ModusIconName } from "./icons/ModusIconUtilities"; @@ -246,11 +250,11 @@ export namespace Components { /** * (optional) The style of the button */ - "buttonStyle": 'borderless' | 'fill' | 'outline'; + "buttonStyle": ButtonStyle; /** * (optional) The color of the button */ - "color": 'danger' | 'primary' | 'secondary' | 'tertiary'; + "color": ButtonColor; /** * (optional) Disables the button. */ @@ -271,6 +275,10 @@ export namespace Components { * (optional) Takes the icon name and shows the icon aligned to the right of the button text. */ "rightIcon": string; + /** + * Set the button to active or inactive + */ + "setActive": (isActive: boolean) => Promise; /** * (optional) Shows a caret icon right side of the button. */ @@ -278,11 +286,41 @@ export namespace Components { /** * (optional) The size of the button. */ - "size": 'small' | 'medium' | 'large'; + "size": ButtonSize; /** * (Optional) Button types */ - "type": 'button' | 'reset' | 'submit'; + "type": ButtonType; + } + interface ModusButtonGroup { + /** + * (optional) The button group's aria-disabled state. + */ + "ariaDisabled": string | null; + /** + * (optional) The button group's aria-label. + */ + "ariaLabel": string; + /** + * (optional) The style of the buttons in the group + */ + "buttonStyle": ButtonStyle; + /** + * (optional) The color of the buttons in the group + */ + "color": ButtonColor; + /** + * (optional) Disables the button group. + */ + "disabled": boolean; + /** + * (optional) The selection type of buttons + */ + "selectionType": ButtonGroupSelectionType; + /** + * (optional) The size of the buttons + */ + "size": ButtonSize; } interface ModusCard { /** @@ -349,6 +387,10 @@ export namespace Components { "tabIndexValue": string | number; } interface ModusChip { + /** + * (optional) Whether the chip is active. + */ + "active": boolean; /** * (optional) The chip's aria-label. */ @@ -744,6 +786,10 @@ export namespace Components { * (optional) Set the primary logo to display when the screen size is greater than 576 pixels, and the secondary logo to display when the screen size is less than or equal to 576 pixels. */ "logoOptions": ModusNavbarLogoOptions; + /** + * (optional) Whether to show badge on top of notification + */ + "notificationCount": number; /** * (required) Profile menu options. */ @@ -941,7 +987,7 @@ export namespace Components { */ "checkedId": string; /** - * The radio button group name. + * The radio button group name. Used to group individual radio elements into one group. */ "name": string; /** @@ -1312,10 +1358,18 @@ export namespace Components { * (optional) Sets autofocus on the input. */ "autoFocusInput": boolean; + /** + * (optional) Capitalization behavior when using a non-traditional keyboard (e.g. microphone, touch screen) + */ + "autocapitalize": 'none' | 'off' | 'sentences' | 'on' | 'words' | 'characters'; /** * (optional) Sets autocomplete on the input. */ "autocomplete": string | null; + /** + * (optional) Whether to activate automatic correction while the user is editing this field in Safari. + */ + "autocorrect": boolean | 'off' | 'on'; /** * (optional) Whether the input has a clear button. */ @@ -1324,6 +1378,10 @@ export namespace Components { * (optional) Whether the input is disabled. */ "disabled": boolean; + /** + * (optional) Which action label to present for the enter key on virtual keyboards. + */ + "enterkeyhint": 'enter' | 'done' | 'go' | 'next' | 'previous' | 'search' | 'send'; /** * (optional) The input's error state text. */ @@ -1360,6 +1418,10 @@ export namespace Components { * (optional) The input's minimum length. */ "minLength": number; + /** + * (optional) The input's pattern HTML attribute. + */ + "pattern": string; /** * (optional) The input's placeholder text. */ @@ -1376,6 +1438,10 @@ export namespace Components { * (optional) The input's size. */ "size": 'medium' | 'large'; + /** + * (optional) Whether to enable spell checking. + */ + "spellcheck": boolean; /** * (optional) The input's text alignment. */ @@ -1480,6 +1546,10 @@ export namespace Components { * (optional) Whether the toast has a dismiss button. */ "dismissible": boolean; + /** + * (optional) Role taken by the toast. Defaults to 'status'. + */ + "role": 'alert' | 'log' | 'marquee' | 'status' | 'timer'; /** * (optional) Whether to show the toasts' icon. */ @@ -1575,6 +1645,10 @@ export namespace Components { */ "focusItem": () => Promise; "initTreeViewItem": (newValue: TreeViewItemOptions) => Promise; + /** + * To be set true when the tree item is an expandable last child + */ + "isLastChild": boolean; /** * (required) Label for the tree item */ @@ -1583,6 +1657,7 @@ export namespace Components { * (required) Unique tree item identifier */ "nodeId": string; + "setChildren": () => Promise; /** * (optional) Tab Index for the tree item */ @@ -1614,6 +1689,10 @@ export interface ModusButtonCustomEvent extends CustomEvent { detail: T; target: HTMLModusButtonElement; } +export interface ModusButtonGroupCustomEvent extends CustomEvent { + detail: T; + target: HTMLModusButtonGroupElement; +} export interface ModusCheckboxCustomEvent extends CustomEvent { detail: T; target: HTMLModusCheckboxElement; @@ -1852,6 +1931,24 @@ declare global { prototype: HTMLModusButtonElement; new (): HTMLModusButtonElement; }; + interface HTMLModusButtonGroupElementEventMap { + "buttonGroupClick": unknown; + "buttonSelectionChange": HTMLModusButtonElement[]; + } + interface HTMLModusButtonGroupElement extends Components.ModusButtonGroup, HTMLStencilElement { + addEventListener(type: K, listener: (this: HTMLModusButtonGroupElement, ev: ModusButtonGroupCustomEvent) => any, options?: boolean | AddEventListenerOptions): void; + addEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; + addEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void; + addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void; + removeEventListener(type: K, listener: (this: HTMLModusButtonGroupElement, ev: ModusButtonGroupCustomEvent) => any, options?: boolean | EventListenerOptions): void; + removeEventListener(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void; + removeEventListener(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void; + removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; + } + var HTMLModusButtonGroupElement: { + prototype: HTMLModusButtonGroupElement; + new (): HTMLModusButtonGroupElement; + }; interface HTMLModusCardElement extends Components.ModusCard, HTMLStencilElement { } var HTMLModusCardElement: { @@ -2368,7 +2465,7 @@ declare global { new (): HTMLModusTableFillerColumnElement; }; interface HTMLModusTableRowActionsElementEventMap { - "overflowRowActions": any; + "overflowRowActions": unknown; } interface HTMLModusTableRowActionsElement extends Components.ModusTableRowActions, HTMLStencilElement { addEventListener(type: K, listener: (this: HTMLModusTableRowActionsElement, ev: ModusTableRowActionsCustomEvent) => any, options?: boolean | AddEventListenerOptions): void; @@ -2496,6 +2593,7 @@ declare global { }; interface HTMLModusTreeViewItemElementEventMap { "checkboxClick": boolean; + "itemLabelChange": string; "itemClick": boolean; "itemExpandToggle": boolean; "itemAdded": HTMLElement; @@ -2524,6 +2622,7 @@ declare global { "modus-badge": HTMLModusBadgeElement; "modus-breadcrumb": HTMLModusBreadcrumbElement; "modus-button": HTMLModusButtonElement; + "modus-button-group": HTMLModusButtonGroupElement; "modus-card": HTMLModusCardElement; "modus-checkbox": HTMLModusCheckboxElement; "modus-chip": HTMLModusChipElement; @@ -2805,11 +2904,11 @@ declare namespace LocalJSX { /** * (optional) The style of the button */ - "buttonStyle"?: 'borderless' | 'fill' | 'outline'; + "buttonStyle"?: ButtonStyle; /** * (optional) The color of the button */ - "color"?: 'danger' | 'primary' | 'secondary' | 'tertiary'; + "color"?: ButtonColor; /** * (optional) Disables the button. */ @@ -2837,11 +2936,49 @@ declare namespace LocalJSX { /** * (optional) The size of the button. */ - "size"?: 'small' | 'medium' | 'large'; + "size"?: ButtonSize; /** * (Optional) Button types */ - "type"?: 'button' | 'reset' | 'submit'; + "type"?: ButtonType; + } + interface ModusButtonGroup { + /** + * (optional) The button group's aria-disabled state. + */ + "ariaDisabled"?: string | null; + /** + * (optional) The button group's aria-label. + */ + "ariaLabel"?: string; + /** + * (optional) The style of the buttons in the group + */ + "buttonStyle"?: ButtonStyle; + /** + * (optional) The color of the buttons in the group + */ + "color"?: ButtonColor; + /** + * (optional) Disables the button group. + */ + "disabled"?: boolean; + /** + * Event emitted when a button is clicked + */ + "onButtonGroupClick"?: (event: ModusButtonGroupCustomEvent) => void; + /** + * Event emitted when the selection changes + */ + "onButtonSelectionChange"?: (event: ModusButtonGroupCustomEvent) => void; + /** + * (optional) The selection type of buttons + */ + "selectionType"?: ButtonGroupSelectionType; + /** + * (optional) The size of the buttons + */ + "size"?: ButtonSize; } interface ModusCard { /** @@ -2908,6 +3045,10 @@ declare namespace LocalJSX { "tabIndexValue"?: string | number; } interface ModusChip { + /** + * (optional) Whether the chip is active. + */ + "active"?: boolean; /** * (optional) The chip's aria-label. */ @@ -3341,6 +3482,10 @@ declare namespace LocalJSX { * (optional) Set the primary logo to display when the screen size is greater than 576 pixels, and the secondary logo to display when the screen size is less than or equal to 576 pixels. */ "logoOptions"?: ModusNavbarLogoOptions; + /** + * (optional) Whether to show badge on top of notification + */ + "notificationCount"?: number; /** * An event that fires when an apps menu app opens. */ @@ -3601,7 +3746,7 @@ declare namespace LocalJSX { */ "checkedId"?: string; /** - * The radio button group name. + * The radio button group name. Used to group individual radio elements into one group. */ "name"?: string; /** @@ -4004,7 +4149,7 @@ declare namespace LocalJSX { } interface ModusTableRowActions { "context"?: TableContext; - "onOverflowRowActions"?: (event: ModusTableRowActionsCustomEvent) => void; + "onOverflowRowActions"?: (event: ModusTableRowActionsCustomEvent) => void; "row"?: Row; } interface ModusTableRowActionsCell { @@ -4042,10 +4187,18 @@ declare namespace LocalJSX { * (optional) Sets autofocus on the input. */ "autoFocusInput"?: boolean; + /** + * (optional) Capitalization behavior when using a non-traditional keyboard (e.g. microphone, touch screen) + */ + "autocapitalize"?: 'none' | 'off' | 'sentences' | 'on' | 'words' | 'characters'; /** * (optional) Sets autocomplete on the input. */ "autocomplete"?: string | null; + /** + * (optional) Whether to activate automatic correction while the user is editing this field in Safari. + */ + "autocorrect"?: boolean | 'off' | 'on'; /** * (optional) Whether the input has a clear button. */ @@ -4054,6 +4207,10 @@ declare namespace LocalJSX { * (optional) Whether the input is disabled. */ "disabled"?: boolean; + /** + * (optional) Which action label to present for the enter key on virtual keyboards. + */ + "enterkeyhint"?: 'enter' | 'done' | 'go' | 'next' | 'previous' | 'search' | 'send'; /** * (optional) The input's error state text. */ @@ -4090,6 +4247,10 @@ declare namespace LocalJSX { * An event that fires on input value change. */ "onValueChange"?: (event: ModusTextInputCustomEvent) => void; + /** + * (optional) The input's pattern HTML attribute. + */ + "pattern"?: string; /** * (optional) The input's placeholder text. */ @@ -4106,6 +4267,10 @@ declare namespace LocalJSX { * (optional) The input's size. */ "size"?: 'medium' | 'large'; + /** + * (optional) Whether to enable spell checking. + */ + "spellcheck"?: boolean; /** * (optional) The input's text alignment. */ @@ -4218,6 +4383,10 @@ declare namespace LocalJSX { * An event that fires when the toast is dismissed */ "onDismissClick"?: (event: ModusToastCustomEvent) => void; + /** + * (optional) Role taken by the toast. Defaults to 'status'. + */ + "role"?: 'alert' | 'log' | 'marquee' | 'status' | 'timer'; /** * (optional) Whether to show the toasts' icon. */ @@ -4308,6 +4477,10 @@ declare namespace LocalJSX { * (optional) Changes the label field into a text box */ "editable"?: boolean; + /** + * To be set true when the tree item is an expandable last child + */ + "isLastChild"?: boolean; /** * (required) Label for the tree item */ @@ -4333,6 +4506,10 @@ declare namespace LocalJSX { * An event that fires on tree item expand/collapse */ "onItemExpandToggle"?: (event: ModusTreeViewItemCustomEvent) => void; + /** + * An event that fires on tree item label changes + */ + "onItemLabelChange"?: (event: ModusTreeViewItemCustomEvent) => void; /** * (optional) Tab Index for the tree item */ @@ -4347,6 +4524,7 @@ declare namespace LocalJSX { "modus-badge": ModusBadge; "modus-breadcrumb": ModusBreadcrumb; "modus-button": ModusButton; + "modus-button-group": ModusButtonGroup; "modus-card": ModusCard; "modus-checkbox": ModusCheckbox; "modus-chip": ModusChip; @@ -4409,6 +4587,7 @@ declare module "@stencil/core" { "modus-badge": LocalJSX.ModusBadge & JSXBase.HTMLAttributes; "modus-breadcrumb": LocalJSX.ModusBreadcrumb & JSXBase.HTMLAttributes; "modus-button": LocalJSX.ModusButton & JSXBase.HTMLAttributes; + "modus-button-group": LocalJSX.ModusButtonGroup & JSXBase.HTMLAttributes; "modus-card": LocalJSX.ModusCard & JSXBase.HTMLAttributes; "modus-checkbox": LocalJSX.ModusCheckbox & JSXBase.HTMLAttributes; "modus-chip": LocalJSX.ModusChip & JSXBase.HTMLAttributes; diff --git a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.e2e.ts b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.e2e.ts index 1a27e9ad1..6131d58ab 100644 --- a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.e2e.ts +++ b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.e2e.ts @@ -55,7 +55,7 @@ describe('modus-accordion-item', () => { await page.setContent(''); const component = await page.find('modus-accordion-item'); const headerElement = await page.find('modus-accordion-item >>> .header'); - const iconElement = await page.find('modus-accordion-item >>> .icon-expand-less'); + const iconElement = await page.find('modus-accordion-item >>> .icon-expand-more'); let iconComputedStyle = await iconElement.getComputedStyle(); expect(headerElement).toHaveClass('standard'); expect(iconComputedStyle['height']).toEqual('24px'); @@ -114,14 +114,14 @@ describe('modus-accordion-item', () => { await page.waitForChanges(); const component = await page.find('modus-accordion-item'); - const element = await page.find('modus-accordion-item >>> .icon-expand-less'); - expect(element).toHaveClass('icon-expand-less'); - expect(element).not.toHaveClass('icon-expand-less-circle'); + const element = await page.find('modus-accordion-item >>> .icon-expand-more'); + expect(element).toHaveClass('icon-expand-more'); + expect(element).not.toHaveClass('icon-expand-more-circle'); component.setProperty('expandButtonType', 'circleArrow'); await page.waitForChanges(); - expect(element).toHaveClass('icon-expand-less-circle'); - expect(element).not.toHaveClass('icon-expand-less'); + expect(element).toHaveClass('icon-expand-more-circle'); + expect(element).not.toHaveClass('icon-expand-more'); }); it('renders changes to the icon prop', async () => { diff --git a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.scss b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.scss index a2f093707..1ebbbf902 100644 --- a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.scss +++ b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.scss @@ -9,6 +9,20 @@ font-family: $primary-font; position: relative; + &[aria-expanded='true'] { + .header:has(div svg.icon-expand-more) { + border-left: 4px solid $modus-accordion-item-expanded-border-left-color; + padding-left: 12px; + } + } + + // Accordion body left border + &:has(div svg.icon-expand-more) { + .body { + box-shadow: 4px 0 0 $modus-accordion-item-expanded-border-left-color inset; + } + } + .header { align-items: center; cursor: pointer; @@ -16,10 +30,9 @@ font-size: $rem-16px; font-weight: $font-weight-semi-bold; height: 48px; + padding: 0 16px; .icon { - margin-left: 8px; - margin-right: 0; margin-top: 4px; } @@ -32,6 +45,10 @@ color: $modus-accordion-item-header-expand-color; } + &.expanded:has(div svg.icon-expand-more) { + background-color: $modus-accordion-item-header-expanded-bg; + } + &:hover:not(.disabled) { background-color: $modus-accordion-item-header-hover-bg; } @@ -41,15 +58,10 @@ height: 32px; } - .title { - padding-left: $rem-8px; - } - .chevron-container { align-items: center; display: flex; margin-left: auto; - margin-right: $rem-8px; transition: transform 0.2s ease-in-out; &.reverse { @@ -69,7 +81,7 @@ .body-content { font-size: $rem-14px; - padding: $rem-16px $rem-8px; + padding: $rem-16px; } &.collapse:not(.show) { @@ -89,3 +101,9 @@ } } } + +.accordion-item:has(> .body.collapsing) .header:has(div svg.icon-expand-more) { + background-color: $modus-accordion-item-header-expanded-bg; + border-left: 4px solid var(--modus-blue); + padding-left: 12px; +} diff --git a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.spec.ts b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.spec.ts index 554cf2045..5b8a61af0 100644 --- a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.spec.ts +++ b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.spec.ts @@ -14,8 +14,8 @@ describe('modus-accordion-item', () => { @@ -42,8 +42,8 @@ describe('modus-accordion-item', () => { diff --git a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.tsx b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.tsx index 43359a23d..4062355b6 100644 --- a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.tsx +++ b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.tsx @@ -1,8 +1,8 @@ -// eslint-disable-next-line +// eslint-disable-next-line @typescript-eslint/no-unused-vars import { Component, Event, EventEmitter, Prop, h } from '@stencil/core'; import { generateElementId } from '../../utils/utils'; -import { IconExpandLessCircle } from '../../icons/generated-icons/IconExpandLessCircle'; -import { IconExpandLess } from '../../icons/generated-icons/IconExpandLess'; +import { IconExpandMoreCircle } from '../../icons/generated-icons/IconExpandMoreCircle'; +import { IconExpandMore } from '../../icons/generated-icons/IconExpandMore'; import { ModusIconMap } from '../../icons/ModusIconMap'; import { JSX } from '@stencil/core/internal'; @@ -111,7 +111,7 @@ export class ModusAccordionItem { // Trick to restart an element's animation // see https://www.charistheo.io/blog/2021/02/restart-a-css-animation-with-javascript/#restarting-a-css-animation - // taken from: https://getbootstrap.com/docs/5.2/dist/js/bootstrap.js + // taken from: https://getbootstrap.com/docs/5.3/dist/js/bootstrap.js reflow = (element) => { element.offsetHeight; // eslint-disable-line no-unused-expressions }; @@ -151,9 +151,9 @@ export class ModusAccordionItem { class={`chevron-container ${this.expanded ? 'reverse' : ''} `} ref={(el) => (this.chevronContainerRef = el)}> {this.expandButtonType == 'circleArrow' ? ( - + ) : ( - + )} } diff --git a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.vars.scss b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.vars.scss index c14cb82e1..7d8d22b75 100644 --- a/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.vars.scss +++ b/stencil-workspace/src/components/modus-accordion-item/modus-accordion-item.vars.scss @@ -4,3 +4,8 @@ $modus-accordion-item-color: var(--modus-accordion-item-color, #252a2e) !default $modus-accordion-item-chevron-color: var(--modus-chevron-color, #6a6e79) !default; $modus-accordion-item-header-hover-bg: var(--modus-accordion-item-header-hover-bg, #e0e1e9) !default; $modus-accordion-item-header-expand-color: var(--modus-accordion-item-header-expand-color, #252a2e) !default; +$modus-accordion-item-header-expanded-bg: var(--modus-accordion-item-header-expanded-bg, #dcedf9) !default; // Blue Pale +$modus-accordion-item-expanded-border-left-color: var( + --modus-accordion-item-expanded-border-left-color, + #0063a3 +) !default; // Blue diff --git a/stencil-workspace/src/components/modus-accordion/modus-accordion.e2e.ts b/stencil-workspace/src/components/modus-accordion/modus-accordion.e2e.ts new file mode 100644 index 000000000..7a41dbcc3 --- /dev/null +++ b/stencil-workspace/src/components/modus-accordion/modus-accordion.e2e.ts @@ -0,0 +1,39 @@ +import { newE2EPage } from '@stencil/core/testing'; + +describe('modus-alert', () => { + it('renders', async () => { + const page = await newE2EPage(); + + await page.setContent(''); + const element = await page.find('modus-accordion'); + expect(element).toHaveClass('hydrated'); + }); + + it('renders aria-label on alert div when set', async () => { + const page = await newE2EPage(); + + await page.setContent(''); + let element = await page.find('modus-accordion >>> div.accordion'); + expect(element).toBeDefined(); + expect(element).toHaveAttribute('aria-label'); + expect(element.getAttribute('aria-label')).toEqual('test label'); + }); + + it('does not render aria-label on alert div when not set', async () => { + const page = await newE2EPage(); + + await page.setContent(''); + let element = await page.find('modus-accordion >>> div.accordion'); + expect(element).toBeDefined(); + expect(element).not.toHaveAttribute('aria-label'); + }); + + it('does not render aria-label on alert div when set to empty string', async () => { + const page = await newE2EPage(); + + await page.setContent(''); + let element = await page.find('modus-accordion >>> div.accordion'); + expect(element).toBeDefined(); + expect(element).not.toHaveAttribute('aria-label'); + }); +}); diff --git a/stencil-workspace/src/components/modus-accordion/modus-accordion.tsx b/stencil-workspace/src/components/modus-accordion/modus-accordion.tsx index 285abe76a..03e9fbf93 100644 --- a/stencil-workspace/src/components/modus-accordion/modus-accordion.tsx +++ b/stencil-workspace/src/components/modus-accordion/modus-accordion.tsx @@ -12,7 +12,7 @@ export class ModusAccordion { render(): unknown { return ( -
+
); diff --git a/stencil-workspace/src/components/modus-alert/modus-alert.e2e.ts b/stencil-workspace/src/components/modus-alert/modus-alert.e2e.ts index a86ca16cb..ce595816a 100644 --- a/stencil-workspace/src/components/modus-alert/modus-alert.e2e.ts +++ b/stencil-workspace/src/components/modus-alert/modus-alert.e2e.ts @@ -23,6 +23,34 @@ describe('modus-alert', () => { expect(element).toBeNull(); }); + it('renders aria-label on alert div when set', async () => { + const page = await newE2EPage(); + + await page.setContent(''); + let element = await page.find('modus-alert >>> div.alert'); + expect(element).toBeDefined(); + expect(element).toHaveAttribute('aria-label'); + expect(element.getAttribute('aria-label')).toEqual('test label'); + }); + + it('does not render aria-label on alert div when not set', async () => { + const page = await newE2EPage(); + + await page.setContent(''); + let element = await page.find('modus-alert >>> div.alert'); + expect(element).toBeDefined(); + expect(element).not.toHaveAttribute('aria-label'); + }); + + it('does not render aria-label on alert div when set to empty string', async () => { + const page = await newE2EPage(); + + await page.setContent(''); + let element = await page.find('modus-alert >>> div.alert'); + expect(element).toBeDefined(); + expect(element).not.toHaveAttribute('aria-label'); + }); + it('renders changes to the message prop', async () => { const page = await newE2EPage(); diff --git a/stencil-workspace/src/components/modus-alert/modus-alert.spec.ts b/stencil-workspace/src/components/modus-alert/modus-alert.spec.ts index dccde1d87..96abc38a8 100644 --- a/stencil-workspace/src/components/modus-alert/modus-alert.spec.ts +++ b/stencil-workspace/src/components/modus-alert/modus-alert.spec.ts @@ -10,7 +10,7 @@ describe('modus-alert', () => { expect(root).toEqualHtml(` -