diff --git a/libs/angular/src/directives/text-drag.directive.ts b/libs/angular/src/directives/text-drag.directive.ts new file mode 100644 index 0000000000..da3e70d1de --- /dev/null +++ b/libs/angular/src/directives/text-drag.directive.ts @@ -0,0 +1,22 @@ +import { Directive, HostListener, Input } from "@angular/core"; + +@Directive({ + selector: "[appTextDrag]", + standalone: true, + host: { + draggable: "true", + class: "tw-cursor-move", + }, +}) +export class TextDragDirective { + @Input({ + alias: "appTextDrag", + required: true, + }) + data = ""; + + @HostListener("dragstart", ["$event"]) + onDragStart(event: DragEvent) { + event.dataTransfer.setData("text", this.data); + } +} diff --git a/libs/angular/src/jslib.module.ts b/libs/angular/src/jslib.module.ts index bebac42fd8..4f5a8f6673 100644 --- a/libs/angular/src/jslib.module.ts +++ b/libs/angular/src/jslib.module.ts @@ -43,6 +43,7 @@ import { LaunchClickDirective } from "./directives/launch-click.directive"; import { NotPremiumDirective } from "./directives/not-premium.directive"; import { StopClickDirective } from "./directives/stop-click.directive"; import { StopPropDirective } from "./directives/stop-prop.directive"; +import { TextDragDirective } from "./directives/text-drag.directive"; import { TrueFalseValueDirective } from "./directives/true-false-value.directive"; import { CreditCardNumberPipe } from "./pipes/credit-card-number.pipe"; import { PluralizePipe } from "./pipes/pluralize.pipe"; @@ -81,6 +82,7 @@ import { IconComponent } from "./vault/components/icon.component"; IconModule, LinkModule, IconModule, + TextDragDirective, ], declarations: [ A11yInvalidDirective, @@ -150,6 +152,7 @@ import { IconComponent } from "./vault/components/icon.component"; NoInvoicesComponent, ManageTaxInformationComponent, TwoFactorIconComponent, + TextDragDirective, ], providers: [ CreditCardNumberPipe, diff --git a/libs/vault/src/cipher-view/additional-options/additional-options.component.html b/libs/vault/src/cipher-view/additional-options/additional-options.component.html index d6fa4732d0..cc74d4e3a6 100644 --- a/libs/vault/src/cipher-view/additional-options/additional-options.component.html +++ b/libs/vault/src/cipher-view/additional-options/additional-options.component.html @@ -4,8 +4,8 @@ - {{ "note" | i18n }} - + {{ "note" | i18n }} + - {{ "expiration" | i18n }} + {{ "expiration" | i18n }} - {{ "securityCode" | i18n }} + {{ "securityCode" | i18n }} - {{ field.name }} + {{ field.name }} - {{ field.name }} + {{ field.name }} - {{ field.name }} + + {{ field.name }} + {{ "cfTypeLinked" | i18n }}: {{ field.name }} diff --git a/libs/vault/src/cipher-view/item-details/item-details-v2.component.html b/libs/vault/src/cipher-view/item-details/item-details-v2.component.html index b6b4256440..28bd0bd258 100644 --- a/libs/vault/src/cipher-view/item-details/item-details-v2.component.html +++ b/libs/vault/src/cipher-view/item-details/item-details-v2.component.html @@ -7,11 +7,12 @@ [disableMargin]="!cipher.collectionIds?.length && !showOwnership && !cipher.folderId" [disableReadOnlyBorder]="!cipher.collectionIds?.length && !showOwnership && !cipher.folderId" > - + {{ "itemName" | i18n }} - + {{ "username" | i18n }} - {{ "password" | i18n }} + {{ "password" | i18n }} - {{ "typePasskey" | i18n }} + {{ "typePasskey" | i18n }} + - {{ "verificationCodeTotp" | i18n }} - {{ "name" | i18n }} - + {{ "name" | i18n }} + - {{ "username" | i18n }} - + {{ "username" | i18n }} + - {{ "company" | i18n }} - + {{ "company" | i18n }} + - {{ "passportNumber" | i18n }} + {{ + "passportNumber" | i18n + }} - {{ "licenseNumber" | i18n }} - + {{ + "licenseNumber" | i18n + }} + - {{ "phone" | i18n }} - + {{ "phone" | i18n }} + - {{ "address" | i18n }} + {{ "address" | i18n }}