Skip to content

Commit

Permalink
Merged in bugfix/SHIBUI-1805 (pull request #475)
Browse files Browse the repository at this point in the history
Added asterisk for required property
  • Loading branch information
rmathis committed Apr 21, 2021
2 parents 97fcfbf + 4363bd2 commit 67f7718
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,10 @@
"title": "label.match",
"description": "tooltip.match",
"type": "string",
"widget": {
"id": "string",
"required": true
},
"visibleIf": {
"@type": [
"Regex"
Expand Down
2 changes: 1 addition & 1 deletion ui/src/app/schema-form/widget/string/string.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<label [for]="formProperty._canonicalPath" class="d-flex justify-content-between control-label">
<span>
{{ schema.title | translate }}&nbsp;
<i class="fa fa-asterisk text-danger" aria-hidden="true" *ngIf="required"></i>
<i class="fa fa-asterisk text-danger" aria-hidden="true" *ngIf="required || schema.widget.required"></i>
<span *ngIf="required" class="sr-only required"><translate-i18n key="message.required">required</translate-i18n></span>
</span>
<span *ngIf="schema.description">
Expand Down

0 comments on commit 67f7718

Please sign in to comment.