1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-11-11 10:10:25 +01:00

[PM-9825] Remove margin from last field in section (#10315)

* Added disableMargin to the last field in a section

* simplified disableMargin input
This commit is contained in:
SmithThe4th 2024-07-29 16:42:27 -04:00 committed by GitHub
parent 2103cb4591
commit 0bbbe5e139
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 18 additions and 11 deletions

View File

@ -8,7 +8,10 @@
<bit-label>{{ "notes" | i18n }}</bit-label>
<textarea bitInput formControlName="notes"></textarea>
</bit-form-field>
<bit-form-control *ngIf="passwordRepromptEnabled$ | async">
<bit-form-control
*ngIf="passwordRepromptEnabled$ | async"
[disableMargin]="hasCustomFields || isPartialEdit"
>
<input type="checkbox" bitCheckbox formControlName="reprompt" />
<bit-label>{{ "passwordPrompt" | i18n }}</bit-label>
</bit-form-control>

View File

@ -51,7 +51,7 @@
</bit-form-field>
</div>
<bit-form-field>
<bit-form-field disableMargin>
<bit-label>{{ "securityCode" | i18n }}</bit-label>
<input id="cardCode" bitInput formControlName="code" type="password" />
<button

View File

@ -12,7 +12,7 @@
<div
*ngFor="let field of fields.controls; let i = index"
[formGroupName]="i"
class="tw-flex tw-p-3 -tw-mx-3 tw-gap-4 tw-bg-background tw-rounded-lg first:-tw-mt-3 last-of-type:tw-mb-3"
class="tw-flex tw-p-3 -tw-mx-3 tw-gap-4 tw-bg-background tw-rounded-lg first:-tw-mt-3 last-of-type:tw-mb-0"
[ngClass]="{
'tw-items-center': field.value.type === FieldType.Boolean,
}"

View File

@ -41,7 +41,7 @@
</bit-label>
<input bitInput formControlName="username" />
</bit-form-field>
<bit-form-field>
<bit-form-field disableMargin>
<bit-label>
{{ "company" | i18n }}
</bit-label>
@ -80,7 +80,7 @@
data-testid="visibility-for-passport-number"
></button>
</bit-form-field>
<bit-form-field>
<bit-form-field disableMargin>
<bit-label>
{{ "licenseNumber" | i18n }}
</bit-label>
@ -99,7 +99,7 @@
</bit-label>
<input bitInput formControlName="email" />
</bit-form-field>
<bit-form-field>
<bit-form-field disableMargin>
<bit-label>
{{ "phone" | i18n }}
</bit-label>
@ -148,7 +148,7 @@
</bit-label>
<input bitInput formControlName="postalCode" />
</bit-form-field>
<bit-form-field>
<bit-form-field disableMargin>
<bit-label>
{{ "country" | i18n }}
</bit-label>

View File

@ -18,7 +18,11 @@
<input bitInput formControlName="name" />
</bit-form-field>
<div class="tw-flex tw-flex-wrap tw-gap-1">
<bit-form-field class="tw-flex-1" *ngIf="showOwnership">
<bit-form-field
class="tw-flex-1"
*ngIf="showOwnership"
[disableMargin]="!showCollectionsControl"
>
<bit-label>{{ "owner" | i18n }}</bit-label>
<bit-select formControlName="organizationId">
<bit-option
@ -33,7 +37,7 @@
></bit-option>
</bit-select>
</bit-form-field>
<bit-form-field class="tw-flex-1">
<bit-form-field class="tw-flex-1" [disableMargin]="!showCollectionsControl">
<bit-label>{{ "folder" | i18n }}</bit-label>
<bit-select formControlName="folderId">
<bit-option
@ -45,7 +49,7 @@
</bit-form-field>
</div>
<ng-container *ngIf="showCollectionsControl">
<bit-form-field class="tw-w-full">
<bit-form-field class="tw-w-full" disableMargin>
<bit-label>{{ "collections" | i18n }}</bit-label>
<bit-multi-select
class="tw-w-full"

View File

@ -74,7 +74,7 @@
></button>
</bit-form-field>
<bit-form-field>
<bit-form-field disableMargin>
<bit-label>
{{ "authenticatorKey" | i18n }}
<button