[CL-119] rename slots in nav-item (#6070)

This commit is contained in:
Will Martin 2023-08-21 13:25:57 -04:00 committed by GitHub
parent 203667f3f4
commit cb1b65081a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 7 deletions

View File

@ -29,10 +29,10 @@
</ng-template>
<!-- Show toggle to the left for trees otherwise to the right -->
<ng-container slot-start *ngIf="variant === 'tree'">
<ng-container slot="start" *ngIf="variant === 'tree'">
<ng-container *ngTemplateOutlet="button"></ng-container>
</ng-container>
<ng-container slot-end *ngIf="variant !== 'tree'">
<ng-container slot="end" *ngIf="variant !== 'tree'">
<ng-container *ngTemplateOutlet="button"></ng-container>
</ng-container>
</bit-nav-item>

View File

@ -16,7 +16,7 @@
#slotStart
class="[&>*:focus-visible::before]:!tw-ring-text-alt2 [&>*:hover]:!tw-border-text-alt2 [&>*]:!tw-text-alt2"
>
<ng-content select="[slot-start]"></ng-content>
<ng-content select="[slot=start]"></ng-content>
</div>
<!-- Default content for #slotStart (for consistent sizing) -->
<div
@ -75,7 +75,7 @@
<div
class="tw-flex tw-gap-1 [&>*:focus-visible::before]:!tw-ring-text-alt2 [&>*:hover]:!tw-border-text-alt2 [&>*]:!tw-text-alt2"
>
<ng-content select="[slot-end]"></ng-content>
<ng-content select="[slot=end]"></ng-content>
</div>
</div>
</div>

View File

@ -61,7 +61,7 @@ export const WithChildButtons: Story = {
template: `
<bit-nav-item text="Hello World" [route]="['']" icon="bwi-collection">
<button
slot-start
slot="start"
class="tw-ml-auto"
[bitIconButton]="'bwi-clone'"
[buttonType]="'contrast'"
@ -69,7 +69,7 @@ export const WithChildButtons: Story = {
aria-label="option 1"
></button>
<button
slot-end
slot="end"
class="tw-ml-auto"
[bitIconButton]="'bwi-pencil-square'"
[buttonType]="'contrast'"
@ -77,7 +77,7 @@ export const WithChildButtons: Story = {
aria-label="option 2"
></button>
<button
slot-end
slot="end"
class="tw-ml-auto"
[bitIconButton]="'bwi-check'"
[buttonType]="'contrast'"