@duetds/cli 4.0.50 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts-snapshots/angular-5-chromium-darwin.png +0 -0
- package/templates/angular/14.2.12/src/tests/playwright/playwright.test.ts-snapshots/angular-5-chromium-darwin.png +0 -0
- package/templates/angular/15.0.4/src/tests/playwright/playwright.test.ts-snapshots/angular-5-chromium-darwin.png +0 -0
- package/templates/angular/16.2.0/package.file +1 -1
- package/templates/angular/16.2.0/src/tests/playwright/playwright.test.ts-snapshots/angular-5-chromium-darwin.png +0 -0
- package/templates/angular/17.0.0/package.file +1 -1
- package/templates/angular/17.0.0/src/app/app.module.ts +10 -1
- package/templates/angular/17.0.0/src/app/investment-amount/investment-amount.component.html +2 -0
- package/templates/angular/17.0.0/src/app/investment-amount/investment-amount.component.ts +2 -12
- package/templates/angular/17.0.0/src/app/investment-origin/investment-origin.component.html +8 -8
- package/templates/angular/17.0.0/src/app/investment-origin/investment-origin.component.ts +2 -21
- package/templates/angular/17.0.0/src/app/value-accessors.ts +147 -0
- package/templates/angular/17.0.0/src/tests/playwright/playwright.test.ts-snapshots/angular-5-chromium-darwin.png +0 -0
- package/templates/react/16.14.0/package.file +1 -1
- package/templates/react/19rc/README.md +54 -0
- package/templates/react/19rc/package-lock.json +10713 -0
- package/templates/react/19rc/package.file +39 -0
- package/templates/{angular/12.2.16/playwright.config.ts → react/19rc/playwright.config.mjs} +7 -7
- package/templates/react/19rc/public/index.html +48 -0
- package/templates/react/19rc/src/App.js +140 -0
- package/templates/react/19rc/src/components/Footer.js +23 -0
- package/templates/react/19rc/src/components/Header.js +6 -0
- package/templates/react/19rc/src/components/InvestmentAmount.js +129 -0
- package/templates/react/19rc/src/components/InvestmentOrigin.js +88 -0
- package/templates/react/19rc/src/components/Summary.js +87 -0
- package/templates/react/19rc/src/index.js +17 -0
- package/templates/react/19rc/src/index.scss +2 -0
- package/templates/react/19rc/src/serviceWorker.js +141 -0
- package/templates/{angular/12.2.16/src/tests/playwright/playwright.test.ts → react/19rc/src/tests/playwright/playwright.test.mjs} +14 -14
- package/templates/react/19rc/src/tests/playwright/playwright.test.mjs-snapshots/app-1-chromium-darwin.png +0 -0
- package/templates/react/19rc/src/tests/playwright/playwright.test.mjs-snapshots/app-2-chromium-darwin.png +0 -0
- package/templates/react/19rc/src/tests/playwright/playwright.test.mjs-snapshots/app-3-chromium-darwin.png +0 -0
- package/templates/{angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-4-chromium-darwin.png → react/19rc/src/tests/playwright/playwright.test.mjs-snapshots/app-4-chromium-darwin.png} +0 -0
- package/templates/{angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-5-chromium-darwin.png → react/19rc/src/tests/playwright/playwright.test.mjs-snapshots/app-5-chromium-darwin.png} +0 -0
- package/templates/{angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots → react/19rc/src/tests/playwright/playwright.test.mjs-snapshots}/code-chromium-darwin.json +1 -1
- package/templates/angular/12.2.16/.browserlistrc +0 -16
- package/templates/angular/12.2.16/.depcheckrc +0 -2
- package/templates/angular/12.2.16/.editorconfig +0 -16
- package/templates/angular/12.2.16/.eslintrc.json +0 -51
- package/templates/angular/12.2.16/.prettierignore +0 -3
- package/templates/angular/12.2.16/.prettierrc +0 -14
- package/templates/angular/12.2.16/README.md +0 -32
- package/templates/angular/12.2.16/angular.json +0 -122
- package/templates/angular/12.2.16/config/jest.base.ts +0 -17
- package/templates/angular/12.2.16/config/jest.setup.ts +0 -24
- package/templates/angular/12.2.16/package.file +0 -58
- package/templates/angular/12.2.16/src/app/agreement.model.ts +0 -3
- package/templates/angular/12.2.16/src/app/app-routing.module.ts +0 -11
- package/templates/angular/12.2.16/src/app/app.component.html +0 -5
- package/templates/angular/12.2.16/src/app/app.component.scss +0 -0
- package/templates/angular/12.2.16/src/app/app.component.ts +0 -10
- package/templates/angular/12.2.16/src/app/app.module.ts +0 -21
- package/templates/angular/12.2.16/src/app/currency-formatter.service.ts +0 -12
- package/templates/angular/12.2.16/src/app/footer/footer.component.html +0 -22
- package/templates/angular/12.2.16/src/app/footer/footer.component.scss +0 -0
- package/templates/angular/12.2.16/src/app/footer/footer.component.ts +0 -10
- package/templates/angular/12.2.16/src/app/header/header.component.html +0 -1
- package/templates/angular/12.2.16/src/app/header/header.component.scss +0 -0
- package/templates/angular/12.2.16/src/app/header/header.component.ts +0 -10
- package/templates/angular/12.2.16/src/app/index-page/index-page.component.html +0 -49
- package/templates/angular/12.2.16/src/app/index-page/index-page.component.scss +0 -0
- package/templates/angular/12.2.16/src/app/index-page/index-page.component.ts +0 -61
- package/templates/angular/12.2.16/src/app/investment-amount/investment-amount.component.html +0 -87
- package/templates/angular/12.2.16/src/app/investment-amount/investment-amount.component.scss +0 -0
- package/templates/angular/12.2.16/src/app/investment-amount/investment-amount.component.ts +0 -31
- package/templates/angular/12.2.16/src/app/investment-origin/investment-origin.component.html +0 -12
- package/templates/angular/12.2.16/src/app/investment-origin/investment-origin.component.scss +0 -0
- package/templates/angular/12.2.16/src/app/investment-origin/investment-origin.component.ts +0 -24
- package/templates/angular/12.2.16/src/app/summary/summary.component.html +0 -74
- package/templates/angular/12.2.16/src/app/summary/summary.component.scss +0 -0
- package/templates/angular/12.2.16/src/app/summary/summary.component.ts +0 -16
- package/templates/angular/12.2.16/src/assets/.gitkeep +0 -0
- package/templates/angular/12.2.16/src/environments/environment.prod.ts +0 -3
- package/templates/angular/12.2.16/src/environments/environment.ts +0 -16
- package/templates/angular/12.2.16/src/index.html +0 -24
- package/templates/angular/12.2.16/src/main.ts +0 -13
- package/templates/angular/12.2.16/src/polyfills.ts +0 -62
- package/templates/angular/12.2.16/src/styles.scss +0 -3
- package/templates/angular/12.2.16/src/tests/app.test.ts +0 -13
- package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-1-chromium-darwin.png +0 -0
- package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-2-chromium-darwin.png +0 -0
- package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-3-chromium-darwin.png +0 -0
- package/templates/angular/12.2.16/src/utils/string.utils.ts +0 -1
- package/templates/angular/12.2.16/tsconfig.app.json +0 -9
- package/templates/angular/12.2.16/tsconfig.base.json +0 -17
- package/templates/angular/12.2.16/tsconfig.json +0 -8
- package/templates/angular/12.2.16/tsconfig.spec.json +0 -15
- package/templates/angular/12.2.16/tslint.json +0 -92
- /package/templates/{angular/12.2.16 → react/19rc}/LICENSE.md +0 -0
- /package/templates/{angular/12.2.16/src → react/19rc/public}/assets/img/android-chrome-192x192.png +0 -0
- /package/templates/{angular/12.2.16/src → react/19rc/public}/assets/img/apple-touch-icon-180x180.png +0 -0
- /package/templates/{angular/12.2.16/src → react/19rc/public}/assets/img/splash-screen-icon-512x512.png +0 -0
- /package/templates/{angular/12.2.16/src → react/19rc/public}/favicon.ico +0 -0
- /package/templates/{angular/12.2.16/src → react/19rc/public}/manifest.json +0 -0
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { Injectable } from "@angular/core"
|
|
2
|
-
import { currencyFormatFI } from "../utils/string.utils"
|
|
3
|
-
|
|
4
|
-
@Injectable({
|
|
5
|
-
providedIn: "root"
|
|
6
|
-
})
|
|
7
|
-
export class CurrencyFormatterService {
|
|
8
|
-
|
|
9
|
-
format(value: number) {
|
|
10
|
-
return currencyFormatFI.format(value)
|
|
11
|
-
}
|
|
12
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
<duet-footer
|
|
2
|
-
variation="simple"
|
|
3
|
-
language="fi"
|
|
4
|
-
[menu]="[
|
|
5
|
-
{
|
|
6
|
-
label: 'Turvallisuus ja käyttöehdot',
|
|
7
|
-
href: '#',
|
|
8
|
-
external: 'true'
|
|
9
|
-
},
|
|
10
|
-
{
|
|
11
|
-
label: 'Evästeet',
|
|
12
|
-
href: '#',
|
|
13
|
-
external: 'true'
|
|
14
|
-
},
|
|
15
|
-
{
|
|
16
|
-
label: 'Henkilötietojen käsittely',
|
|
17
|
-
href: '#',
|
|
18
|
-
external: 'true'
|
|
19
|
-
}
|
|
20
|
-
]"
|
|
21
|
-
>
|
|
22
|
-
</duet-footer>
|
|
File without changes
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<duet-header logo-href="" [back]="{ label: 'Takaisin', href: '/' }"></duet-header>
|
|
File without changes
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
<duet-layout center>
|
|
2
|
-
<div slot="top" role="region">
|
|
3
|
-
<duet-spacer breakpoint="large" size="x-large"></duet-spacer>
|
|
4
|
-
<duet-heading level="h1" visual-level="h2">Pääotsikko</duet-heading>
|
|
5
|
-
<duet-spacer></duet-spacer>
|
|
6
|
-
</div>
|
|
7
|
-
<div slot="main">
|
|
8
|
-
<form [formGroup]="form" (ngSubmit)="handleSubmit($event)">
|
|
9
|
-
<duet-stepper [selected]="currentStep" (duetStepChange)="handleStepChange($event)">
|
|
10
|
-
<duet-step heading="Perustiedot" formGroupName="investmentAmount">
|
|
11
|
-
<duet-paragraph>
|
|
12
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore etdolore
|
|
13
|
-
magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip.
|
|
14
|
-
</duet-paragraph>
|
|
15
|
-
<app-investment-amount
|
|
16
|
-
[form]="form.get('investmentAmount')"
|
|
17
|
-
[agreements]="agreements"
|
|
18
|
-
></app-investment-amount>
|
|
19
|
-
<duet-spacer></duet-spacer>
|
|
20
|
-
<duet-button margin="none" variation="primary" (click)="handleNextClick($event)" [disabled]="form.invalid"
|
|
21
|
-
id="step1">Seuraava</duet-button
|
|
22
|
-
>
|
|
23
|
-
</duet-step>
|
|
24
|
-
|
|
25
|
-
<duet-step heading="Tarkemmat tiedot" formGroupName="investmentOrigin">
|
|
26
|
-
<duet-paragraph>
|
|
27
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore etdolore
|
|
28
|
-
magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip.
|
|
29
|
-
</duet-paragraph>
|
|
30
|
-
<app-investment-origin [form]="form.get('investmentOrigin')"></app-investment-origin>
|
|
31
|
-
<duet-spacer></duet-spacer>
|
|
32
|
-
<duet-button margin="none" variation="primary" (click)="handleNextClick($event)" [disabled]="form.invalid" id="step2">
|
|
33
|
-
Seuraava
|
|
34
|
-
</duet-button>
|
|
35
|
-
</duet-step>
|
|
36
|
-
|
|
37
|
-
<duet-step heading="Yhteenveto">
|
|
38
|
-
<duet-spacer></duet-spacer>
|
|
39
|
-
<app-summary [agreement]="selectedAgreement"></app-summary>
|
|
40
|
-
<duet-spacer></duet-spacer>
|
|
41
|
-
<duet-button submit margin="none" variation="primary" expand [disabled]="form.invalid" id="step3"> Lähetä </duet-button>
|
|
42
|
-
</duet-step>
|
|
43
|
-
</duet-stepper>
|
|
44
|
-
</form>
|
|
45
|
-
</div>
|
|
46
|
-
</duet-layout>
|
|
47
|
-
<duet-modal [active]="completed" heading="You entered the following data:">
|
|
48
|
-
<pre><code>{{ form.value | json }}</code></pre>
|
|
49
|
-
</duet-modal>
|
|
File without changes
|
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { Component } from "@angular/core"
|
|
2
|
-
import { FormBuilder, Validators } from "@angular/forms"
|
|
3
|
-
import { Agreement } from "../agreement.model"
|
|
4
|
-
|
|
5
|
-
import { currencyFormatFI } from "../../utils/string.utils"
|
|
6
|
-
|
|
7
|
-
@Component({
|
|
8
|
-
selector: "app-index-page",
|
|
9
|
-
templateUrl: "./index-page.component.html",
|
|
10
|
-
styleUrls: ["./index-page.component.scss"]
|
|
11
|
-
})
|
|
12
|
-
export class IndexPageComponent {
|
|
13
|
-
constructor(private formBuilder: FormBuilder) {}
|
|
14
|
-
|
|
15
|
-
currentStep = 0
|
|
16
|
-
completed = false
|
|
17
|
-
|
|
18
|
-
form = this.formBuilder.group({
|
|
19
|
-
investmentAmount: this.formBuilder.group({
|
|
20
|
-
agreement: [null, [Validators.required]],
|
|
21
|
-
additionalInvestment: 50
|
|
22
|
-
}),
|
|
23
|
-
investmentOrigin: this.formBuilder.group({
|
|
24
|
-
salary: false,
|
|
25
|
-
gift: false,
|
|
26
|
-
heritage: false,
|
|
27
|
-
entrepreneurialIncome: false,
|
|
28
|
-
assets: false,
|
|
29
|
-
otherIncome: false,
|
|
30
|
-
investment: false,
|
|
31
|
-
extras: null
|
|
32
|
-
})
|
|
33
|
-
})
|
|
34
|
-
|
|
35
|
-
agreements: Record<number, Agreement> = {
|
|
36
|
-
1: new Agreement("Vakuutus 1", 2500),
|
|
37
|
-
2: new Agreement("Vakuutus 2", 1000)
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
get selectedAgreement() {
|
|
41
|
-
return this.agreements[this.form.value.investmentAmount.agreement]
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
formatNumber(value: number) {
|
|
45
|
-
return currencyFormatFI.format(value)
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
handleStepChange(event: CustomEvent) {
|
|
49
|
-
this.currentStep = event.detail.toStep
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
handleNextClick(event: Event) {
|
|
53
|
-
event.preventDefault()
|
|
54
|
-
this.currentStep++
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
handleSubmit(event: Event) {
|
|
58
|
-
event.preventDefault()
|
|
59
|
-
this.completed = true
|
|
60
|
-
}
|
|
61
|
-
}
|
package/templates/angular/12.2.16/src/app/investment-amount/investment-amount.component.html
DELETED
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
<ng-container [formGroup]="form">
|
|
2
|
-
<duet-select
|
|
3
|
-
formControlName="agreement"
|
|
4
|
-
expand
|
|
5
|
-
label="Valitse sopimus"
|
|
6
|
-
placeholder="Valitse…"
|
|
7
|
-
[items]="agreementOptions"
|
|
8
|
-
>
|
|
9
|
-
</duet-select>
|
|
10
|
-
<duet-table variation="plain" *ngIf="selectedAgreement">
|
|
11
|
-
<table>
|
|
12
|
-
<thead>
|
|
13
|
-
<tr>
|
|
14
|
-
<th>Sijoituskohde</th>
|
|
15
|
-
<th class="duet-text-right">Osuus</th>
|
|
16
|
-
</tr>
|
|
17
|
-
</thead>
|
|
18
|
-
<tbody>
|
|
19
|
-
<tr>
|
|
20
|
-
<td>
|
|
21
|
-
<duet-button
|
|
22
|
-
variation="plain"
|
|
23
|
-
margin="none"
|
|
24
|
-
padding="none"
|
|
25
|
-
url="https://www.duetds.com/assets/downloads/localtapiola-brand-guidelines.pdf"
|
|
26
|
-
external
|
|
27
|
-
>
|
|
28
|
-
Kohde 1<duet-spacer size="xx-small" direction="horizontal"></duet-spacer>
|
|
29
|
-
<duet-visually-hidden>, avautuu uuteen ikkunaan</duet-visually-hidden>
|
|
30
|
-
</duet-button>
|
|
31
|
-
</td>
|
|
32
|
-
<td class="duet-text-right">25%</td>
|
|
33
|
-
</tr>
|
|
34
|
-
<tr>
|
|
35
|
-
<td>
|
|
36
|
-
<duet-button
|
|
37
|
-
variation="plain"
|
|
38
|
-
margin="none"
|
|
39
|
-
padding="none"
|
|
40
|
-
url="https://www.duetds.com/assets/downloads/localtapiola-brand-guidelines.pdf"
|
|
41
|
-
external
|
|
42
|
-
>
|
|
43
|
-
Kohde 2<duet-spacer size="xx-small" direction="horizontal"></duet-spacer>
|
|
44
|
-
<duet-visually-hidden>, avautuu uuteen ikkunaan</duet-visually-hidden>
|
|
45
|
-
</duet-button>
|
|
46
|
-
</td>
|
|
47
|
-
<td class="duet-text-right">25%</td>
|
|
48
|
-
</tr>
|
|
49
|
-
<tr>
|
|
50
|
-
<td>
|
|
51
|
-
<duet-button
|
|
52
|
-
variation="plain"
|
|
53
|
-
margin="none"
|
|
54
|
-
padding="none"
|
|
55
|
-
url="https://www.duetds.com/assets/downloads/localtapiola-brand-guidelines.pdf"
|
|
56
|
-
external
|
|
57
|
-
>
|
|
58
|
-
Kohde 3<duet-spacer size="xx-small" direction="horizontal"></duet-spacer>
|
|
59
|
-
<duet-visually-hidden>, avautuu uuteen ikkunaan</duet-visually-hidden>
|
|
60
|
-
</duet-button>
|
|
61
|
-
</td>
|
|
62
|
-
<td class="duet-text-right">50%</td>
|
|
63
|
-
</tr>
|
|
64
|
-
</tbody>
|
|
65
|
-
<tfoot>
|
|
66
|
-
<tr>
|
|
67
|
-
<td class="duet-font-weight-semi-bold">Yhteisarvo</td>
|
|
68
|
-
<td class="duet-text-right duet-font-weight-semi-bold duet-font-size-large">
|
|
69
|
-
{{ formatter.format(selectedAgreement.price) }}
|
|
70
|
-
</td>
|
|
71
|
-
</tr>
|
|
72
|
-
</tfoot>
|
|
73
|
-
</table>
|
|
74
|
-
</duet-table>
|
|
75
|
-
<duet-spacer></duet-spacer>
|
|
76
|
-
<duet-card variation="plain" background="gray-lighter">
|
|
77
|
-
<duet-input
|
|
78
|
-
formControlName="additionalInvestment"
|
|
79
|
-
numeric-keyboard
|
|
80
|
-
expand
|
|
81
|
-
label="Syötä summa"
|
|
82
|
-
placeholder="50"
|
|
83
|
-
icon="form-money"
|
|
84
|
-
type="number"
|
|
85
|
-
></duet-input>
|
|
86
|
-
</duet-card>
|
|
87
|
-
</ng-container>
|
package/templates/angular/12.2.16/src/app/investment-amount/investment-amount.component.scss
DELETED
|
File without changes
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import { Component, OnInit, Input } from "@angular/core"
|
|
2
|
-
import { FormGroup } from "@angular/forms"
|
|
3
|
-
import { Agreement } from "../agreement.model"
|
|
4
|
-
import { CurrencyFormatterService } from "../currency-formatter.service"
|
|
5
|
-
|
|
6
|
-
@Component({
|
|
7
|
-
selector: "app-investment-amount",
|
|
8
|
-
templateUrl: "./investment-amount.component.html",
|
|
9
|
-
styleUrls: ["./investment-amount.component.scss"]
|
|
10
|
-
})
|
|
11
|
-
export class InvestmentAmountComponent implements OnInit {
|
|
12
|
-
@Input() agreements: Record<number, Agreement>
|
|
13
|
-
@Input() form: FormGroup
|
|
14
|
-
|
|
15
|
-
constructor(public formatter: CurrencyFormatterService) {}
|
|
16
|
-
|
|
17
|
-
ngOnInit(): void {}
|
|
18
|
-
|
|
19
|
-
get selectedAgreement() {
|
|
20
|
-
return this.agreements[this.form.value.agreement]
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
get agreementOptions() {
|
|
24
|
-
return Object.entries(this.agreements).map(([value, { label, price }]) => {
|
|
25
|
-
return {
|
|
26
|
-
value,
|
|
27
|
-
label: `${label} - ${this.formatter.format(price)}`
|
|
28
|
-
}
|
|
29
|
-
})
|
|
30
|
-
}
|
|
31
|
-
}
|
package/templates/angular/12.2.16/src/app/investment-origin/investment-origin.component.html
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
<ng-container [formGroup]="form">
|
|
2
|
-
<duet-checkbox formControlName="salary" label="Valinta 1"></duet-checkbox>
|
|
3
|
-
<duet-checkbox formControlName="gift" label="Valinta 2"></duet-checkbox>
|
|
4
|
-
<duet-checkbox formControlName="heritage" label="Valinta 3"></duet-checkbox>
|
|
5
|
-
<duet-checkbox formControlName="entrepreneurialIncome" label="Valinta 4"></duet-checkbox>
|
|
6
|
-
<duet-checkbox formControlName="assets" label="Valinta 5"></duet-checkbox>
|
|
7
|
-
<duet-checkbox formControlName="otherIncome" label="Valinta 6"></duet-checkbox>
|
|
8
|
-
<duet-checkbox label="Muu, mikä?" (duetChange)="handleExtrasChange($event)"></duet-checkbox>
|
|
9
|
-
<div *ngIf="hasExtras">
|
|
10
|
-
<duet-input formControlName="extras" label="Kerro sijoitettavien varojen muu alkuperä" label-hidden></duet-input>
|
|
11
|
-
</div>
|
|
12
|
-
</ng-container>
|
package/templates/angular/12.2.16/src/app/investment-origin/investment-origin.component.scss
DELETED
|
File without changes
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Component, OnInit, Input } from "@angular/core"
|
|
2
|
-
import { FormGroup } from "@angular/forms"
|
|
3
|
-
|
|
4
|
-
@Component({
|
|
5
|
-
selector: "app-investment-origin",
|
|
6
|
-
templateUrl: "./investment-origin.component.html",
|
|
7
|
-
styleUrls: ["./investment-origin.component.scss"]
|
|
8
|
-
})
|
|
9
|
-
export class InvestmentOriginComponent implements OnInit {
|
|
10
|
-
@Input() form: FormGroup
|
|
11
|
-
hasExtras = false
|
|
12
|
-
|
|
13
|
-
constructor() {}
|
|
14
|
-
|
|
15
|
-
ngOnInit(): void {}
|
|
16
|
-
|
|
17
|
-
handleExtrasChange(event: CustomEvent) {
|
|
18
|
-
this.hasExtras = event.detail.checked
|
|
19
|
-
|
|
20
|
-
if (!event.detail.checked) {
|
|
21
|
-
this.form.get("extras").setValue(null)
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
}
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
<ng-container *ngIf="agreement">
|
|
2
|
-
<duet-input expand disabled label="Sopimus" [value]="agreement.label"></duet-input>
|
|
3
|
-
<duet-spacer></duet-spacer>
|
|
4
|
-
<duet-paragraph>Valitsemasi vaihtoehto jakautuu seuraavasti:</duet-paragraph>
|
|
5
|
-
<duet-table variation="plain">
|
|
6
|
-
<table>
|
|
7
|
-
<thead>
|
|
8
|
-
<tr>
|
|
9
|
-
<th>Sijoituskohde</th>
|
|
10
|
-
<th>Osuus</th>
|
|
11
|
-
<th class="duet-text-right">Summa</th>
|
|
12
|
-
</tr>
|
|
13
|
-
</thead>
|
|
14
|
-
<tbody>
|
|
15
|
-
<tr>
|
|
16
|
-
<td>
|
|
17
|
-
<duet-button
|
|
18
|
-
variation="plain"
|
|
19
|
-
margin="none"
|
|
20
|
-
padding="none"
|
|
21
|
-
url="https://www.duetds.com/assets/downloads/localtapiola-brand-guidelines.pdf"
|
|
22
|
-
external
|
|
23
|
-
>
|
|
24
|
-
Kohde 1<duet-spacer size="xx-small" direction="horizontal"></duet-spacer>
|
|
25
|
-
<duet-visually-hidden>, avautuu uuteen ikkunaan</duet-visually-hidden>
|
|
26
|
-
</duet-button>
|
|
27
|
-
</td>
|
|
28
|
-
<td>25%</td>
|
|
29
|
-
<td class="duet-text-right">{{ formatter.format(agreement.price * 0.25) }}</td>
|
|
30
|
-
</tr>
|
|
31
|
-
<tr>
|
|
32
|
-
<td>
|
|
33
|
-
<duet-button
|
|
34
|
-
variation="plain"
|
|
35
|
-
margin="none"
|
|
36
|
-
padding="none"
|
|
37
|
-
url="https://www.duetds.com/assets/downloads/localtapiola-brand-guidelines.pdf"
|
|
38
|
-
external
|
|
39
|
-
>
|
|
40
|
-
Kohde 2<duet-spacer size="xx-small" direction="horizontal"></duet-spacer>
|
|
41
|
-
<duet-visually-hidden>, avautuu uuteen ikkunaan</duet-visually-hidden>
|
|
42
|
-
</duet-button>
|
|
43
|
-
</td>
|
|
44
|
-
<td>25%</td>
|
|
45
|
-
<td class="duet-text-right">{{ formatter.format(agreement.price * 0.25) }}</td>
|
|
46
|
-
</tr>
|
|
47
|
-
<tr>
|
|
48
|
-
<td>
|
|
49
|
-
<duet-button
|
|
50
|
-
variation="plain"
|
|
51
|
-
margin="none"
|
|
52
|
-
padding="none"
|
|
53
|
-
url="https://www.duetds.com/assets/downloads/localtapiola-brand-guidelines.pdf"
|
|
54
|
-
external
|
|
55
|
-
>
|
|
56
|
-
Kohde 3<duet-spacer size="xx-small" direction="horizontal"></duet-spacer>
|
|
57
|
-
<duet-visually-hidden>, avautuu uuteen ikkunaan</duet-visually-hidden>
|
|
58
|
-
</duet-button>
|
|
59
|
-
</td>
|
|
60
|
-
<td>50%</td>
|
|
61
|
-
<td class="duet-text-right">{{ formatter.format(agreement.price * 0.5) }}</td>
|
|
62
|
-
</tr>
|
|
63
|
-
</tbody>
|
|
64
|
-
<tfoot>
|
|
65
|
-
<tr>
|
|
66
|
-
<td colspan="2" class="duet-font-weight-semi-bold">Sijoitettava summa</td>
|
|
67
|
-
<td class="duet-text-right duet-font-weight-semi-bold duet-font-size-large">
|
|
68
|
-
{{ formatter.format(agreement.price) }}
|
|
69
|
-
</td>
|
|
70
|
-
</tr>
|
|
71
|
-
</tfoot>
|
|
72
|
-
</table>
|
|
73
|
-
</duet-table>
|
|
74
|
-
</ng-container>
|
|
File without changes
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { Component, OnInit, Input } from "@angular/core"
|
|
2
|
-
import { Agreement } from "../agreement.model"
|
|
3
|
-
import { CurrencyFormatterService } from "../currency-formatter.service"
|
|
4
|
-
|
|
5
|
-
@Component({
|
|
6
|
-
selector: "app-summary",
|
|
7
|
-
templateUrl: "./summary.component.html",
|
|
8
|
-
styleUrls: ["./summary.component.scss"]
|
|
9
|
-
})
|
|
10
|
-
export class SummaryComponent implements OnInit {
|
|
11
|
-
@Input() agreement: Agreement
|
|
12
|
-
|
|
13
|
-
constructor(public formatter: CurrencyFormatterService) {}
|
|
14
|
-
|
|
15
|
-
ngOnInit(): void {}
|
|
16
|
-
}
|
|
File without changes
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
// This file can be replaced during build by using the `fileReplacements` array.
|
|
2
|
-
// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.
|
|
3
|
-
// The list of file replacements can be found in `angular.json`.
|
|
4
|
-
|
|
5
|
-
export const environment = {
|
|
6
|
-
production: false
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
/*
|
|
10
|
-
* For easier debugging in development mode, you can import the following file
|
|
11
|
-
* to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.
|
|
12
|
-
*
|
|
13
|
-
* This import should be commented out in production mode because it will have a negative impact
|
|
14
|
-
* on performance if an error is thrown.
|
|
15
|
-
*/
|
|
16
|
-
// import 'zone.js/dist/zone-error'; // Included with Angular CLI.
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="fi" class="duet-sticky-footer duet-bg-gradient">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="utf-8" />
|
|
5
|
-
<base href="/" />
|
|
6
|
-
<title>LähiTapiola</title>
|
|
7
|
-
<meta name="author" content="LähiTapiola" />
|
|
8
|
-
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
|
9
|
-
<meta name="format-detection" content="telephone=no" />
|
|
10
|
-
<meta name="robots" content="noindex,nofollow" />
|
|
11
|
-
<link rel="apple-touch-icon" href="assets/img/apple-touch-icon-180x180.png" />
|
|
12
|
-
<link rel="manifest" href="manifest.json" />
|
|
13
|
-
<link
|
|
14
|
-
rel="stylesheet"
|
|
15
|
-
href="https://cdn.duetds.com/api/fonts/1.3.12/lib/localtapiola.css"
|
|
16
|
-
integrity="sha384-5JYmtSD7nykpUvSmTW1CHMoBDkBZUpUmG0vuh+NUVtZag3F75Kr7+/JU3J7JV6Wq"
|
|
17
|
-
crossorigin="anonymous"
|
|
18
|
-
/>
|
|
19
|
-
<link rel="icon" type="image/x-icon" href="favicon.ico" />
|
|
20
|
-
</head>
|
|
21
|
-
<body>
|
|
22
|
-
<app-root class="duet-sticky-body"></app-root>
|
|
23
|
-
</body>
|
|
24
|
-
</html>
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { enableProdMode } from "@angular/core"
|
|
2
|
-
import { platformBrowserDynamic } from "@angular/platform-browser-dynamic"
|
|
3
|
-
|
|
4
|
-
import { AppModule } from "./app/app.module"
|
|
5
|
-
import { environment } from "./environments/environment"
|
|
6
|
-
|
|
7
|
-
if (environment.production) {
|
|
8
|
-
enableProdMode()
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
platformBrowserDynamic()
|
|
12
|
-
.bootstrapModule(AppModule)
|
|
13
|
-
.catch(err => console.error(err))
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This file includes polyfills needed by Angular and is loaded before the app.
|
|
3
|
-
* You can add your own extra polyfills to this file.
|
|
4
|
-
*
|
|
5
|
-
* This file is divided into 2 sections:
|
|
6
|
-
* 1. Browser polyfills. These are applied before loading ZoneJS and are sorted by browsers.
|
|
7
|
-
* 2. Application imports. Files imported after ZoneJS that should be loaded before your main
|
|
8
|
-
* file.
|
|
9
|
-
*
|
|
10
|
-
* The current setup is for so-called "evergreen" browsers; the last versions of browsers that
|
|
11
|
-
* automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera),
|
|
12
|
-
* Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile.
|
|
13
|
-
*
|
|
14
|
-
* Learn more in https://angular.io/guide/browser-support
|
|
15
|
-
*/
|
|
16
|
-
|
|
17
|
-
/***************************************************************************************************
|
|
18
|
-
* BROWSER POLYFILLS
|
|
19
|
-
*/
|
|
20
|
-
|
|
21
|
-
/** IE10 and IE11 requires the following for NgClass support on SVG elements */
|
|
22
|
-
// import 'classlist.js'; // Run `npm install --save classlist.js`.
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* Web Animations `@angular/platform-browser/animations`
|
|
26
|
-
* Only required if AnimationBuilder is used within the application and using IE/Edge or Safari.
|
|
27
|
-
* Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0).
|
|
28
|
-
*/
|
|
29
|
-
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
* By default, zone.js will patch all possible macroTask and DomEvents
|
|
33
|
-
* user can disable parts of macroTask/DomEvents patch by setting following flags
|
|
34
|
-
* because those flags need to be set before `zone.js` being loaded, and webpack
|
|
35
|
-
* will put import in the top of bundle, so user need to create a separate file
|
|
36
|
-
* in this directory (for example: zone-flags.ts), and put the following flags
|
|
37
|
-
* into that file, and then add the following code before importing zone.js.
|
|
38
|
-
* import './zone-flags';
|
|
39
|
-
*
|
|
40
|
-
* The flags allowed in zone-flags.ts are listed here.
|
|
41
|
-
*
|
|
42
|
-
* The following flags will work for all browsers.
|
|
43
|
-
*
|
|
44
|
-
* (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame
|
|
45
|
-
* (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick
|
|
46
|
-
* (window as any).__zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames
|
|
47
|
-
*
|
|
48
|
-
* in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js
|
|
49
|
-
* with the following flag, it will bypass `zone.js` patch for IE/Edge
|
|
50
|
-
*
|
|
51
|
-
* (window as any).__Zone_enable_cross_context_check = true;
|
|
52
|
-
*
|
|
53
|
-
*/
|
|
54
|
-
|
|
55
|
-
/***************************************************************************************************
|
|
56
|
-
* Zone JS is required by default for Angular itself.
|
|
57
|
-
*/
|
|
58
|
-
import "zone.js/dist/zone" // Included with Angular CLI.
|
|
59
|
-
|
|
60
|
-
/***************************************************************************************************
|
|
61
|
-
* APPLICATION IMPORTS
|
|
62
|
-
*/
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import {currencyFormatFI} from "../utils/string.utils"
|
|
2
|
-
|
|
3
|
-
describe('Example test of the jest setup running', () => {
|
|
4
|
-
test('formatter should format correctly', () => {
|
|
5
|
-
console.log(currencyFormatFI)
|
|
6
|
-
const formatStub = currencyFormatFI.format(12.90)
|
|
7
|
-
expect(formatStub).toBe("12,90 €")
|
|
8
|
-
});
|
|
9
|
-
|
|
10
|
-
test('Should do another thing', () => {
|
|
11
|
-
// do something...
|
|
12
|
-
});
|
|
13
|
-
});
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export const currencyFormatFI = new Intl.NumberFormat("fi-FI", { style: "currency", currency: "EUR" })
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compileOnSave": false,
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"esModuleInterop":true,
|
|
5
|
-
"baseUrl": "./",
|
|
6
|
-
"outDir": "./dist/out-tsc",
|
|
7
|
-
"sourceMap": true,
|
|
8
|
-
"declaration": false,
|
|
9
|
-
"downlevelIteration": true,
|
|
10
|
-
"experimentalDecorators": true,
|
|
11
|
-
"moduleResolution": "node",
|
|
12
|
-
"importHelpers": true,
|
|
13
|
-
"target": "es2015",
|
|
14
|
-
"module": "es2020",
|
|
15
|
-
"lib": ["es2018", "dom"]
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "./tsconfig.base.json",
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"outDir": "./out-tsc/app",
|
|
5
|
-
"types": ["jest","jest-image-snapshot","node"],
|
|
6
|
-
"esModuleInterop": true,
|
|
7
|
-
"emitDecoratorMetadata": true
|
|
8
|
-
},
|
|
9
|
-
"files": ["src/main.ts", "src/polyfills.ts"],
|
|
10
|
-
"include": ["src/**/*.d.ts",
|
|
11
|
-
"src/**/*.spec.ts",
|
|
12
|
-
"src/**/*.test.ts",
|
|
13
|
-
"src/**/*.spec.tsx",
|
|
14
|
-
"src/**/*.test.tsx"]
|
|
15
|
-
}
|