Skip to content

Commit

Permalink
[NAB-327] - Release 2.0.0
Browse files Browse the repository at this point in the history
- small changes in spacing of field list in form builder
  • Loading branch information
mazarijuraj committed Aug 6, 2024
1 parent d1bc535 commit 0e744bf
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 11 deletions.
2 changes: 1 addition & 1 deletion src/app/form-builder/field-list/field-list.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ <h3 class="field-list-heading">Data fields</h3>
(click)="addNewField(fieldType.type, component)">
<div class="field-list-mat-list-item-title">
<mat-icon class="icon-color">drag_indicator</mat-icon>
<span>{{shortening(component.title)}}</span>
<span>{{component.title}}</span>
</div>
</mat-list-item>
</mat-expansion-panel>
Expand Down
4 changes: 2 additions & 2 deletions src/app/form-builder/field-list/field-list.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@

.field-list-mat-list-item {
height: 40px;
padding-left: 0;
padding-right: 0;
padding-left: 8px;
padding-right: 4px;
}

.field-list-mat-list-item:hover {
Expand Down
8 changes: 0 additions & 8 deletions src/app/form-builder/field-list/field-list.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,14 +113,6 @@ export class FieldListComponent implements OnInit, AfterViewInit {
this.dragStartHandler($event, true);
}

shortening(title: string) {
if (title?.length > 10) {
const tmp = title.slice(0, 10);
return tmp + '...';
}
return title;
}

containsSearchExpression(item: DataVariable): boolean {
const search = this.existingFieldsSearchInput.toLocaleLowerCase();
return item.title?.value?.toLocaleLowerCase()?.includes(search)
Expand Down
17 changes: 17 additions & 0 deletions src/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -212,3 +212,20 @@ nab-simulation-mode {
}
}

.field-list-expansion-panel {
.mat-expansion-panel-header {
padding-left: 8px;
padding-right: 4px;
}
.mat-expansion-panel-body {
padding-left: 8px;
padding-right: 4px;
}
.mat-expanded {
margin-bottom: 0;
margin-top: 0;
}
.mat-expansion-panel-header.mat-expanded {
height: 40px;
}
}

0 comments on commit 0e744bf

Please sign in to comment.