bitwarden-estensione-browser/libs/components/src/form-field/prefix.directive.ts

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

23 lines
480 B
TypeScript
Raw Normal View History

2022-06-02 09:34:13 +02:00
import { Directive, HostBinding, Input } from "@angular/core";
export const PrefixClasses = [
"tw-block",
"tw-px-3",
"tw-py-1.5",
"tw-bg-background-alt",
"tw-border",
"tw-border-solid",
"tw-border-secondary-500",
"tw-text-muted",
"tw-rounded-none",
2022-06-02 09:34:13 +02:00
];
@Directive({
selector: "[bitPrefix]",
})
export class BitPrefixDirective {
@HostBinding("class") @Input() get classList() {
return PrefixClasses.concat(["tw-border-r-0", "first:tw-rounded-l"]);
2022-06-02 09:34:13 +02:00
}
}