Update empty state (#14916)

Fixes #14899

Updates the empty states according to latest design in Figma.
This commit is contained in:
Icaro Motta 2023-01-27 15:24:30 -03:00 committed by GitHub
parent 6002672e7c
commit 55caf0230e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 33 additions and 14 deletions

View File

@ -47,4 +47,14 @@
:padding-vertical 12}) :padding-vertical 12})
(def empty-title (def empty-title
{:padding-bottom 2}) {:padding-bottom 2
:color colors/white})
(def empty-subtitle
{:color colors/white})
(def empty-rectangle-placeholder
{:width 120
:height 120
:background-color colors/danger-50
:margin-bottom 20})

View File

@ -29,17 +29,24 @@
(defn empty-tab (defn empty-tab
[] []
(let [filter-status (rf/sub [:activity-center/filter-status])]
[rn/view [rn/view
{:style style/empty-container {:style style/empty-container
:accessibility-label :empty-notifications} :accessibility-label :empty-notifications}
[quo/icon :i/placeholder] [rn/view {:style style/empty-rectangle-placeholder}]
[quo/text [quo/text
{:size :paragraph-1 {:size :paragraph-1
:style style/empty-title :style style/empty-title
:weight :semi-bold} :weight :semi-bold}
(i18n/label :t/empty-notifications-title)] (i18n/label (if (= :unread filter-status)
[quo/text {:size :paragraph-2} :t/empty-notifications-title-unread
(i18n/label :t/empty-notifications-subtitle)]]) :t/empty-notifications-title-read))]
[quo/text
{:size :paragraph-2
:style style/empty-subtitle}
(i18n/label (if (= :unread filter-status)
:t/empty-notifications-subtitle-unread
:t/empty-notifications-subtitle-read))]]))
(defn tabs (defn tabs
[] []

View File

@ -1909,8 +1909,10 @@
"bold": "Bold", "bold": "Bold",
"italic": "Italic", "italic": "Italic",
"strikethrough": "Strikethrough", "strikethrough": "Strikethrough",
"empty-notifications-title": "No notifications", "empty-notifications-title-unread": "You're up to date",
"empty-notifications-subtitle": "Your notifications will be here", "empty-notifications-subtitle-unread": "Unread notifications will be here",
"empty-notifications-title-read": "No notifications",
"empty-notifications-subtitle-read": "Your notifications will be here",
"add-text": "Add text", "add-text": "Add text",
"send": "Send", "send": "Send",
"unmute-group": "Unmute group", "unmute-group": "Unmute group",