-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into feature/dev-3315-cardinality-for-comments-on…
…-regions-set-to-optional * main: chore: add sentry error tracker (#1507) feat: watermark with radios and inputs (DEV-3313) (#1506) fix: resource class item autocomplete refresh and loading (DEV-3371) (#1504) feat: watermark with radios and inputs (DEV-3313) (#1502) refactor: type chip list input component (#1501) refactor: type common input (#1500)
- Loading branch information
Showing
54 changed files
with
2,647 additions
and
232 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -60,3 +60,6 @@ Thumbs.db | |
#E2E | ||
/.nx | ||
apps/dsp-app/cypress/screenshots | ||
|
||
# Sentry Config File | ||
.sentryclirc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { IMask } from 'angular-imask'; | ||
|
||
export class InputMasks { | ||
public static minMaxInputMask(min: number, max: number) { | ||
return { | ||
mask: IMask.MaskedNumber, | ||
min, | ||
max, | ||
autofix: true, | ||
}; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 4 additions & 11 deletions
15
apps/dsp-app/src/app/project/common-input/common-input.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,22 @@ | ||
import { Component, Input } from '@angular/core'; | ||
import { FormControl, FormGroup } from '@angular/forms'; | ||
import { FormControl } from '@angular/forms'; | ||
|
||
@Component({ | ||
selector: 'app-common-input', | ||
template: ` | ||
<mat-form-field style="width: 100%"> | ||
<mat-icon matIconPrefix *ngIf="prefixIcon">{{ prefixIcon }}</mat-icon> | ||
<input matInput [placeholder]="placeholder" [formControl]="formControl" /> | ||
<mat-error *ngIf="formControl.errors as errors"> | ||
<input matInput [placeholder]="placeholder" [formControl]="control" /> | ||
<mat-error *ngIf="control.errors as errors"> | ||
{{ errors | humanReadableError: validatorErrors }} | ||
</mat-error> | ||
</mat-form-field> | ||
`, | ||
styles: [':host { display: block;}'], | ||
}) | ||
export class CommonInputComponent { | ||
@Input() formGroup: FormGroup; | ||
@Input() controlName: string; | ||
@Input() control: FormControl<string>; | ||
@Input() placeholder: string; | ||
@Input() prefixIcon: string | null = null; | ||
@Input() validatorErrors: { errorKey: string; message: string }[] | null = null; | ||
|
||
get formControl() { | ||
return this.formGroup.controls[this.controlName] as FormControl; | ||
} | ||
|
||
protected readonly FormGroup = FormGroup; | ||
} |
85 changes: 85 additions & 0 deletions
85
apps/dsp-app/src/app/project/image-settings/image-display-absolute.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
import { Component, Input } from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'app-image-display-absolute', | ||
template: ` <div class="frame"> | ||
<div class="text">Example image with width: {{ bigWidth }}px</div> | ||
<div | ||
[ngStyle]="{ width: (widthPx / bigWidth) * 300 + 'px', height: (widthPx / bigWidth) * 200 + 'px' }" | ||
class="back-rectangle"> | ||
<div class="arrow left-arrow"></div> | ||
<div class="arrow right-arrow"></div> | ||
<div class="helper"> | ||
{{ widthPx }} | ||
px | ||
</div> | ||
</div> | ||
</div>`, | ||
styles: [ | ||
` | ||
.frame { | ||
background: gray; | ||
width: 300px; | ||
height: 200px; | ||
position: relative; | ||
} | ||
.text { | ||
width: 100%; | ||
text-align: center; | ||
position: absolute; | ||
top: 20px; | ||
} | ||
.back-rectangle { | ||
background: darkgray; | ||
bottom: 0; | ||
right: 0; | ||
position: absolute; | ||
} | ||
.helper { | ||
position: absolute; | ||
bottom: -40px; | ||
right: 0; | ||
text-align: center; | ||
width: 100%; | ||
min-width: 100px; | ||
} | ||
.arrow { | ||
position: absolute; | ||
height: 1px; /* Adjust the height of the stick */ | ||
background-color: red; /* Adjust the color of the stick */ | ||
right: 0; | ||
bottom: -20px; | ||
width: 100%; | ||
} | ||
.left-arrow::before, | ||
.right-arrow::before { | ||
content: ''; | ||
position: absolute; | ||
top: -5px; | ||
width: 0; | ||
height: 0; | ||
border-top: 5px solid transparent; /* Adjust the height of the arrow */ | ||
border-bottom: 5px solid transparent; /* Adjust the height of the arrow */ | ||
} | ||
.left-arrow::before { | ||
right: 0; | ||
border-left: 10px solid red; /* Adjust the width and color of the arrow */ | ||
} | ||
.right-arrow::before { | ||
left: 0; | ||
border-right: 10px solid red; /* Adjust the width and color of the arrow */ | ||
} | ||
`, | ||
], | ||
}) | ||
export class ImageDisplayAbsoluteComponent { | ||
@Input() widthPx: number; | ||
readonly bigWidth = 2048; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.