-
Notifications
You must be signed in to change notification settings - Fork 467
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(edit-content) fix comments #28658
- Loading branch information
Showing
6 changed files
with
103 additions
and
78 deletions.
There are no files selected for viewing
11 changes: 8 additions & 3 deletions
11
...t-content/src/lib/components/dot-edit-content-field/dot-edit-content-field.component.scss
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,12 +1,17 @@ | ||
@use "variables" as *; | ||
|
||
:host { | ||
display: block; | ||
display: flex; | ||
flex-direction: column; | ||
height: fit-content; | ||
margin-bottom: 0; | ||
gap: $spacing-1; | ||
|
||
label { | ||
margin: 0; | ||
} | ||
|
||
small { | ||
margin-top: $spacing-1; | ||
display: block; | ||
margin: 0; | ||
} | ||
} |
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
46 changes: 20 additions & 26 deletions
46
...-edit-content-category-field-dialog/dot-edit-content-category-field-dialog.component.scss
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
38 changes: 18 additions & 20 deletions
38
...lib/fields/dot-edit-content-category-field/dot-edit-content-category-field.component.html
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,23 +1,21 @@ | ||
<div class="dot-category-field__wrapper" [ngClass]="{ 'has-categories': values.length }"> | ||
@if (values.length) { | ||
<div class="dot-category-field__categories" data-testId="category-chip-list"> | ||
@for (category of values; track category.id) { | ||
<p-chip | ||
[pTooltip]="category.value" | ||
[removable]="true" | ||
[label]="category.value" | ||
tooltipPosition="top" | ||
styleClass="p-chip-sm" /> | ||
} | ||
</div> | ||
@if (values.length) { | ||
<div class="dot-category-field__categories" data-testId="category-chip-list"> | ||
@for (category of values; track category.id) { | ||
<p-chip | ||
[pTooltip]="category.value" | ||
[removable]="true" | ||
[label]="category.value" | ||
tooltipPosition="top" | ||
styleClass="p-chip-sm" /> | ||
} | ||
</div> | ||
} | ||
|
||
<div class="dot-category-field__select"> | ||
<p-button | ||
[label]="'edit.content.category-field.show-categories-dialog' | dm" | ||
(onClick)="showCategories()" | ||
data-testId="show-dialog-btn" | ||
icon="pi pi-pencil" | ||
styleClass="p-button-sm p-button-text p-button-secondary" /> | ||
</div> | ||
<div class="dot-category-field__select"> | ||
<p-button | ||
[label]="'edit.content.category-field.show-categories-dialog' | dm" | ||
(onClick)="showCategories()" | ||
data-testId="show-dialog-btn" | ||
icon="pi pi-pencil" | ||
styleClass="p-button-sm p-button-text p-button-secondary" /> | ||
</div> |
48 changes: 23 additions & 25 deletions
48
...lib/fields/dot-edit-content-category-field/dot-edit-content-category-field.component.scss
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,34 +1,32 @@ | ||
@use "variables" as *; | ||
|
||
.dot-category-field__wrapper { | ||
.dot-category-field__categories, | ||
.dot-category-field__select { | ||
border: $field-border-size solid $color-palette-gray-400; | ||
display: flex; | ||
flex-wrap: wrap; | ||
align-items: center; | ||
:host { | ||
&.dot-category-field__container--has-categories .dot-category-field__select { | ||
border-radius: 0 0 $border-radius-md $border-radius-md; | ||
} | ||
|
||
.dot-category-field__categories { | ||
padding: $spacing-1; | ||
gap: $spacing-1; | ||
border-radius: $border-radius-md $border-radius-md 0 0; | ||
&.dot-category-field__container--has-categories .dot-category-field__categories { | ||
border-bottom: none; | ||
} | ||
} | ||
|
||
.dot-category-field__select { | ||
height: $field-height-md; | ||
border-radius: $border-radius-md; | ||
padding: 0 $spacing-0; | ||
justify-content: flex-end; | ||
} | ||
.dot-category-field__categories, | ||
.dot-category-field__select { | ||
border: $field-border-size solid $color-palette-gray-400; | ||
display: flex; | ||
flex-wrap: wrap; | ||
align-items: center; | ||
} | ||
|
||
&.has-categories { | ||
.dot-category-field__select { | ||
border-radius: 0 0 $border-radius-md $border-radius-md; | ||
} | ||
.dot-category-field__categories { | ||
padding: $spacing-1; | ||
gap: $spacing-1; | ||
border-radius: $border-radius-md $border-radius-md 0 0; | ||
} | ||
|
||
.dot-category-field__categories { | ||
border-bottom: none; | ||
} | ||
} | ||
.dot-category-field__select { | ||
height: $field-height-md; | ||
border-radius: $border-radius-md; | ||
padding: 0 $spacing-0; | ||
justify-content: flex-end; | ||
} |
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