Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Add static/classic/amo/installed (whatever they're called) themes

Đang mở
#456 5 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
25/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
javascript
Lĩnh vực
frontend

Hướng nghiên cứu

Bắt đầu bằng cách đọc luồng ThemeBuilder và cách sử dụng browser.management API được mô tả trong issue, sau đó theo dõi cách Firefox Color hiện đang lưu trữ và áp dụng các theme. Xác định cách biểu diễn các theme tĩnh, theme đã cài đặt và override đã chọn trước khi triển khai các thay đổi về UI và state. Hoàn tất nghĩa là các theme tĩnh đã cài đặt có thể được hiển thị, chọn, lưu bền vững và áp dụng mà không để theme Firefox Color chiếm quyền kiểm soát.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Priority: p3

So this comes out of a discussion with the add-ons team, and the idea was that we might collaborate on this issue as a changing of the guard, so to speak. I was noodling around with this the other day, but didn't get very far...here's what i was thinking...certainly open to better suggestions:

  1. Use browser.management api to get all installed themes from the user and track which one they have enabled.
  2. Create a new set of redux actions called statics that can manage the state of static themes. I think we'd need to keep a list of installed static themes, a boolean to track if a static theme should override a ff color theme, and a pointer to user's selected static theme. something like
statics.id: // id of last selected static theme
statics.isActive: // boolean if a static theme should override an FF color API theme
statics.list // list of all static themes the user has installed
  1. On the UI side, create a new panel in the ThemeBuilder that renders all the user's static themes. Something like PaginatedStaticPicker.
  2. There are up to six themes that come from Firefox and do not exist in AMO, these are default, dark, compact light, a stripey pastel theme, the browser renaissance theme, and an outer space theme. For each of these we make representations using our theming JSON schema. For AMO themes, we can do a fetch of the BG image of each using the theme id and use that to make a representation of each AMO Theme.
  3. When a user clicks on one of these themes, we update the app state and override the selected FF color theme. We also pass back a message to browser.management to update to the selected static theme.
  4. Next time FF color starts up, it checks to see if statics.isActive is true before taking over and re-theming based on the current FF color theme state
Ngôn ngữ chính
JavaScript
Star
506
Fork
100
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của mozilla/FirefoxColor

Tất cả issue của mozilla/FirefoxColor

Issue tương tự

Thêm issue về JavaScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.