mirror of
https://github.com/bitwarden/browser
synced 2025-12-19 01:33:33 +00:00
[PM-18802] - Autofill Settings Nudges and Settings Badge (#14439)
* autofill nudge * remove undismiss logic * revert change to popup view cache service * move browser autofill logic to platform. cleanup * fix test * adjustments to autofill nudges * add missing provider * updates to autofill nudges * fix date logic * change autofillBrowserSettingsService isBrowserAutofillSettingOverridden to function * fix up browser autofill overridden settings logic * remove check for privacy in isBrowserAutofillSettingOverridden
This commit is contained in:
@@ -23,10 +23,9 @@
|
||||
type="button"
|
||||
buttonType="primary"
|
||||
*ngIf="buttonText"
|
||||
(click)="handleButtonClick()"
|
||||
(click)="handleButtonClick($event)"
|
||||
>
|
||||
{{ buttonText }}
|
||||
<i *ngIf="buttonIcon" [ngClass]="buttonIcon" class="bwi tw-ml-1" aria-hidden="true"></i>
|
||||
</button>
|
||||
|
||||
<ng-content></ng-content>
|
||||
</div>
|
||||
|
||||
@@ -19,11 +19,13 @@ export class SpotlightComponent {
|
||||
@Input() buttonText?: string;
|
||||
// Wheter the component can be dismissed, if true, the component will not show a close button
|
||||
@Input() persistent = false;
|
||||
// Optional icon to display on the button
|
||||
@Input() buttonIcon: string | null = null;
|
||||
@Output() onDismiss = new EventEmitter<void>();
|
||||
@Output() onButtonClick = new EventEmitter<void>();
|
||||
@Output() onButtonClick = new EventEmitter();
|
||||
|
||||
handleButtonClick(): void {
|
||||
this.onButtonClick.emit();
|
||||
handleButtonClick(event: MouseEvent): void {
|
||||
this.onButtonClick.emit(event);
|
||||
}
|
||||
|
||||
handleDismiss(): void {
|
||||
|
||||
@@ -52,9 +52,9 @@ export const Persistent: Story = {
|
||||
},
|
||||
};
|
||||
|
||||
export const WithCustomButton: Story = {
|
||||
export const WithButtonIcon: Story = {
|
||||
args: {
|
||||
buttonText: "Custom Button",
|
||||
buttonIcon: "bwi bwi-external-link",
|
||||
},
|
||||
render: (args) => ({
|
||||
props: args,
|
||||
@@ -62,19 +62,9 @@ export const WithCustomButton: Story = {
|
||||
<bit-spotlight
|
||||
[title]="title"
|
||||
[subtitle]="subtitle"
|
||||
>
|
||||
<button
|
||||
class="tw-w-full"
|
||||
bit-item-content
|
||||
bitButton
|
||||
type="button"
|
||||
buttonType="primary"
|
||||
(click)="handleButtonClick()"
|
||||
>
|
||||
External Link
|
||||
<i slot="end" class="bwi bwi-external-link ml-2" aria-hidden="true"></i>
|
||||
</button>
|
||||
</bit-spotlight>
|
||||
buttonText="External Link"
|
||||
buttonIcon="bwi-external-link"
|
||||
></bit-spotlight>
|
||||
`,
|
||||
}),
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user