Closed Bug 1810215 Opened 1 year ago Closed 8 months ago

Create a reusable CommandButton component

Categories

(Firefox :: about:logins, task, P2)

task

Tracking

()

RESOLVED FIXED
117 Branch
Tracking Status
firefox117 --- fixed

People

(Reporter: serg, Assigned: ssachdev)

References

(Blocks 1 open bug)

Details

(Whiteboard: [fxcm-productive-ux])

Attachments

(3 files)

No description provided.
Attached image image.png

I suspect that component eventually will be in more reusable area, but for now lets just focus on about:logins. We need a button with icon and text.

Assignee: nobody → mtigley
Severity: -- → N/A
Priority: -- → P2
Status: NEW → ASSIGNED
Status: ASSIGNED → NEW
Summary: Extract CommandButton → Create a reusable CommandButton component

Requirements

Renders

  • An optional string describing the command it performs (Ex: “Edit”, “Remove”, etc…)
  • An optional icon
  • Optional tooltip for describing the action

Interactivity

Runs a callback that performs the desired action

Styling

See https://firefoxux.github.io/firefox-desktop-components/?path=/story/ui-widgets-button--regular-button. We should reuse this if possible.

Props

  • onClick: <Function> The function to run when the button is clicked
  • l10nId: Optional <string> An l10n-id that translates to the rendered command string
  • icon: Optional <string> The source URL of the icon to render
  • state: Optional <string> The state of the button
  • disabled: Optional <boolean> Whether or not the button is interactive
  • tooltipText: Optional <string> Tooltip text describing the action of the button
Assignee: mtigley → ssachdev
Status: NEW → ASSIGNED
Blocks: 1832680
Whiteboard: [fxcm-productive-ux]
Blocks: 1844869
Pushed by tgiles@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9636cc512a42
Created a reusable CommandButton component. r=credential-management-reviewers,sgalich,tgiles,mtigley,desktop-theme-reviewers,dao
Pushed by tgiles@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/fcb2279fe728
Added a story file for the reusable CommandButton component. r=credential-management-reviewers,mtigley

Backed out for causing failures on browser_preselect_login.js, browser_parsable_css.js

Backout link

Push with failures - bc6
Push with failures - bc2

Failure log - bc6
Failure log - bc2

Flags: needinfo?(ssachdev)
Pushed by ssachdev@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/8d82e862c269
Created a reusable CommandButton component. r=credential-management-reviewers,sgalich,tgiles,mtigley,desktop-theme-reviewers,dao
Pushed by ssachdev@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/09826d4eb13b
Added a story file for the reusable CommandButton component. r=credential-management-reviewers,mtigley
Status: ASSIGNED → RESOLVED
Closed: 8 months ago
Resolution: --- → FIXED
Target Milestone: --- → 117 Branch
Blocks: 1845753
Flags: needinfo?(ssachdev)
Regressions: 1859809
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: