Eugenio Romano 9e3a4aa49f
[ADF-2563] Improve versioning functionality (#3335)
* change input with textarea

* update file version use now the update content API

* provide way to test read only mode version list

* fix test

* test fix
2018-05-17 11:35:42 +01:00

38 lines
1.6 KiB
HTML

<div class="adf-new-version-max-width">
<mat-radio-group class="adf-new-version-radio-group" [(ngModel)]="semanticVersion">
<mat-radio-button class="adf-new-version-radio-button" [value]="'minor'">{{
'ADF_VERSION_LIST.ACTIONS.UPLOAD.MINOR' |
translate }}
</mat-radio-button>
<mat-radio-button class="adf-new-version-radio-button" [value]="'major'">{{
'ADF_VERSION_LIST.ACTIONS.UPLOAD.MAJOR' |
translate }}
</mat-radio-button>
</mat-radio-group>
<mat-form-field class="adf-new-version-max-width">
<textarea matInput [(ngModel)]="comment" class="adf-new-version-text-area"
placeholder="{{ 'ADF_VERSION_LIST.ACTIONS.UPLOAD.COMMENT' | translate }}"></textarea>
</mat-form-field>
</div>
<div>
<button mat-raised-button (click)="cancelUpload()" class="adf-cancel-button">{{
'ADF_VERSION_LIST.ACTIONS.UPLOAD.CANCEL'| translate }}
</button>
<adf-upload-version-button
data-automation-id="adf-new-version-file-upload"
class="adf-new-version-file-upload"
staticTitle="{{ 'ADF_VERSION_LIST.ACTIONS.UPLOAD.TITLE' | translate }}"
[node]="node"
[disabled]="!canUpload()"
[rootFolderId]="node.parentId"
tooltip="{{ 'ADF_VERSION_LIST.ACTIONS.UPLOAD.TOOLTIP' | translate }}"
[comment]="comment"
[versioning]="true"
[majorVersion]="isMajorVersion()"
(success)="success.emit($event)"
(error)="error.emit($event)">
</adf-upload-version-button>
</div>