From 07d50a7b0c03be2d70ea924bdf594e62acd97a42 Mon Sep 17 00:00:00 2001 From: lunarkid Date: Tue, 19 Jul 2022 09:41:58 +0700 Subject: [PATCH 01/49] improvement(reskin-profile-settings): 1 - tab profile --- .../Datepicker/__snapshots__/index.jsx.snap | 2 +- .../Header/__snapshots__/index.jsx.snap | 75 +- .../AboutMe/__snapshots__/index.jsx.snap | 1134 -------- .../Settings/Profile/AboutMe/index.jsx | 25 - .../Profile/ExternalLinks/AddWebLink.jsx | 18 - .../Profile/ExternalLinks/ExistingLink.jsx | 16 - .../Profile/ExternalLinks/ExistingLinks.jsx | 23 - .../Profile/ExternalLinks/LinkAccounts.jsx | 20 - .../__snapshots__/AddWebLink.jsx.snap | 55 - .../__snapshots__/ExistingLink.jsx.snap | 59 - .../__snapshots__/ExistingLinks.jsx.snap | 11 - .../__snapshots__/LinkAccounts.jsx.snap | 7 - .../__snapshots__/index.jsx.snap | 2341 ----------------- .../Settings/Profile/ExternalLinks/index.jsx | 24 - .../Settings/Profile/Skills/index.jsx | 23 - .../components/Settings/Profile/index.jsx | 28 - .../Settings/__snapshots__/index.jsx.snap | 160 +- src/assets/images/dropdown-arrow.svg | 3 + src/assets/images/icon-banner-selector.svg | 3 + src/assets/images/icon-edit.svg | 4 + src/assets/images/icon-input-calendar.svg | 3 + src/assets/images/icon-upload.svg | 3 + src/assets/images/nav-active-item.svg | 4 +- src/assets/images/settings-add-item.svg | 3 + src/shared/actions/page/settings.js | 4 +- .../components/GUIKit/Datepicker/index.jsx | 21 +- .../index.jsx | 0 .../styles.scss | 5 + .../Settings/ErrorMessage/styles.scss | 10 +- .../components/Settings/FormField/index.jsx | 41 + .../components/Settings/FormField/styles.scss | 28 + .../Settings/FormInputSelect/index.jsx | 26 + .../Settings/FormInputSelect/styles.scss | 25 + .../Settings/FormInputText/index.jsx | 27 + .../Settings/FormInputText/styles.scss | 23 + .../Settings/FormInputTextArea/index.jsx | 27 + .../Settings/FormInputTextArea/styles.scss | 29 + .../components/Settings/Header/index.jsx | 88 +- .../components/Settings/Header/styles.scss | 110 +- .../components/Settings/PageRow/index.jsx | 38 + .../components/Settings/PageRow/styles.scss | 39 + .../Settings/Profile/AboutMe/index.jsx | 190 -- .../Settings/Profile/AboutMe/styles.scss | 96 - .../Profile/BasicInfo/ImageInput/index.jsx | 184 -- .../Profile/BasicInfo/ImageInput/styles.scss | 107 - .../Profile/BasicInfo/Track/index.jsx | 67 - .../Profile/BasicInfo/Track/styles.scss | 82 - .../Settings/Profile/BasicInfo/dropdowns.json | 41 - .../Settings/Profile/BasicInfo/index.jsx | 922 ------- .../Settings/Profile/BasicInfo/styles.scss | 471 ---- .../Settings/Profile/BasicInfo/tracks.jsx | 20 - .../Settings/Profile/Community/Item/index.jsx | 86 - .../Profile/Community/Item/styles.scss | 106 - .../Settings/Profile/Community/data.jsx | 21 - .../Settings/Profile/Community/index.jsx | 185 -- .../Settings/Profile/Community/styles.scss | 59 - .../Profile/Education/List/styles.scss | 29 - .../Settings/Profile/Education/index.jsx | 811 ------ .../Profile/ExternalLinks/AddWebLink.jsx | 132 - .../Profile/ExternalLinks/ExistingLink.jsx | 274 -- .../Profile/ExternalLinks/ExistingLinks.jsx | 134 - .../Profile/ExternalLinks/LinkAccounts.jsx | 141 - .../Settings/Profile/ExternalLinks/index.jsx | 188 -- .../Profile/ExternalLinks/styles.scss | 724 ----- .../Settings/Profile/Hobby/List/styles.scss | 29 - .../Settings/Profile/Hobby/index.jsx | 486 ---- .../Settings/Profile/ImageInput/index.jsx | 136 - .../Settings/Profile/ImageInput/styles.scss | 77 - .../Profile/Language/List/Item/index.jsx | 116 - .../Profile/Language/List/Item/styles.scss | 151 -- .../Settings/Profile/Language/List/index.jsx | 41 - .../Profile/Language/List/styles.scss | 29 - .../Settings/Profile/Language/dropdowns.json | 782 ------ .../Settings/Profile/Language/index.jsx | 634 ----- .../Settings/Profile/Language/styles.scss | 268 -- .../Profile/Organization/List/Item/index.jsx | 67 - .../Organization/List/Item/styles.scss | 102 - .../Profile/Organization/List/index.jsx | 34 - .../Settings/Profile/Organization/index.jsx | 487 ---- .../Settings/Profile/Organization/styles.scss | 279 -- .../Settings/Profile/Skills/index.jsx | 683 ----- .../Settings/Profile/Skills/styles.scss | 441 ---- .../Settings/Profile/Work/List/Item/index.jsx | 95 - .../Profile/Work/List/Item/styles.scss | 153 -- .../Settings/Profile/Work/List/index.jsx | 36 - .../Settings/Profile/Work/index.jsx | 763 ------ .../Settings/Profile/Work/styles.scss | 425 --- .../components/Settings/Profile/index.jsx | 168 -- .../components/Settings/Profile/styles.scss | 50 - .../ProfileSettings/AboutYou/index.jsx | 90 + .../Hobbies}/List/Item/index.jsx | 0 .../Hobbies}/List/Item/styles.scss | 1 + .../Hobbies}/List/index.jsx | 0 .../Hobbies}/List/styles.scss | 7 +- .../ProfileSettings/Hobbies/index.jsx | 138 + .../Hobbies}/styles.scss | 23 +- .../ProfileSettings/ImageInput/index.jsx | 154 ++ .../ProfileSettings/ImageInput/styles.scss | 134 + .../Learning}/List/Item/index.jsx | 2 +- .../Learning}/List/Item/styles.scss | 1 + .../Learning}/List/index.jsx | 0 .../Learning}/List/styles.scss | 7 +- .../ProfileSettings/Learning/index.jsx | 288 ++ .../Learning}/styles.scss | 237 +- .../ProfileSettings/PersonalDetails/index.jsx | 295 +++ .../Settings/ProfileSettings/index.jsx | 1150 ++++++++ .../Settings/ProfileSettings/styles.scss | 211 ++ .../Settings/SettingsBanner/index.jsx | 64 + .../Settings/SettingsBanner/styles.scss | 53 + .../components/Settings/TabSelector/index.jsx | 99 + .../Settings/TabSelector/styles.scss | 120 + .../Settings/Tools/Devices/index.jsx | 2 +- .../Settings/Tools/ServiceProviders/index.jsx | 2 +- .../Settings/Tools/Software/index.jsx | 2 +- .../Settings/Tools/Subscriptions/index.jsx | 2 +- src/shared/components/Settings/constants.js | 31 +- src/shared/components/Settings/index.jsx | 40 +- src/shared/components/Settings/style.scss | 211 +- src/shared/routes/Settings/Router.jsx | 2 +- 119 files changed, 3796 insertions(+), 15757 deletions(-) delete mode 100644 __tests__/shared/components/Settings/Profile/AboutMe/__snapshots__/index.jsx.snap delete mode 100644 __tests__/shared/components/Settings/Profile/AboutMe/index.jsx delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/AddWebLink.jsx delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/ExistingLink.jsx delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/ExistingLinks.jsx delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/LinkAccounts.jsx delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/__snapshots__/AddWebLink.jsx.snap delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/__snapshots__/ExistingLink.jsx.snap delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/__snapshots__/ExistingLinks.jsx.snap delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/__snapshots__/LinkAccounts.jsx.snap delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/__snapshots__/index.jsx.snap delete mode 100644 __tests__/shared/components/Settings/Profile/ExternalLinks/index.jsx delete mode 100644 __tests__/shared/components/Settings/Profile/Skills/index.jsx delete mode 100644 __tests__/shared/components/Settings/Profile/index.jsx create mode 100644 src/assets/images/dropdown-arrow.svg create mode 100644 src/assets/images/icon-banner-selector.svg create mode 100644 src/assets/images/icon-edit.svg create mode 100644 src/assets/images/icon-input-calendar.svg create mode 100644 src/assets/images/icon-upload.svg create mode 100644 src/assets/images/settings-add-item.svg rename src/shared/components/Settings/{CofirmationModal => ConfirmationModal}/index.jsx (100%) rename src/shared/components/Settings/{CofirmationModal => ConfirmationModal}/styles.scss (96%) create mode 100644 src/shared/components/Settings/FormField/index.jsx create mode 100644 src/shared/components/Settings/FormField/styles.scss create mode 100644 src/shared/components/Settings/FormInputSelect/index.jsx create mode 100644 src/shared/components/Settings/FormInputSelect/styles.scss create mode 100644 src/shared/components/Settings/FormInputText/index.jsx create mode 100644 src/shared/components/Settings/FormInputText/styles.scss create mode 100644 src/shared/components/Settings/FormInputTextArea/index.jsx create mode 100644 src/shared/components/Settings/FormInputTextArea/styles.scss create mode 100644 src/shared/components/Settings/PageRow/index.jsx create mode 100644 src/shared/components/Settings/PageRow/styles.scss delete mode 100644 src/shared/components/Settings/Profile/AboutMe/index.jsx delete mode 100644 src/shared/components/Settings/Profile/AboutMe/styles.scss delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/ImageInput/index.jsx delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/ImageInput/styles.scss delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/Track/index.jsx delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/Track/styles.scss delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/dropdowns.json delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/index.jsx delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/styles.scss delete mode 100644 src/shared/components/Settings/Profile/BasicInfo/tracks.jsx delete mode 100644 src/shared/components/Settings/Profile/Community/Item/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Community/Item/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Community/data.jsx delete mode 100644 src/shared/components/Settings/Profile/Community/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Community/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Education/List/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Education/index.jsx delete mode 100644 src/shared/components/Settings/Profile/ExternalLinks/AddWebLink.jsx delete mode 100644 src/shared/components/Settings/Profile/ExternalLinks/ExistingLink.jsx delete mode 100644 src/shared/components/Settings/Profile/ExternalLinks/ExistingLinks.jsx delete mode 100644 src/shared/components/Settings/Profile/ExternalLinks/LinkAccounts.jsx delete mode 100644 src/shared/components/Settings/Profile/ExternalLinks/index.jsx delete mode 100644 src/shared/components/Settings/Profile/ExternalLinks/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Hobby/List/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Hobby/index.jsx delete mode 100644 src/shared/components/Settings/Profile/ImageInput/index.jsx delete mode 100644 src/shared/components/Settings/Profile/ImageInput/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Language/List/Item/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Language/List/Item/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Language/List/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Language/List/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Language/dropdowns.json delete mode 100644 src/shared/components/Settings/Profile/Language/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Language/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Organization/List/Item/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Organization/List/Item/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Organization/List/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Organization/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Organization/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Skills/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Skills/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Work/List/Item/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Work/List/Item/styles.scss delete mode 100644 src/shared/components/Settings/Profile/Work/List/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Work/index.jsx delete mode 100644 src/shared/components/Settings/Profile/Work/styles.scss delete mode 100644 src/shared/components/Settings/Profile/index.jsx delete mode 100644 src/shared/components/Settings/Profile/styles.scss create mode 100644 src/shared/components/Settings/ProfileSettings/AboutYou/index.jsx rename src/shared/components/Settings/{Profile/Hobby => ProfileSettings/Hobbies}/List/Item/index.jsx (100%) rename src/shared/components/Settings/{Profile/Hobby => ProfileSettings/Hobbies}/List/Item/styles.scss (99%) rename src/shared/components/Settings/{Profile/Hobby => ProfileSettings/Hobbies}/List/index.jsx (100%) rename src/shared/components/Settings/{Profile/Organization => ProfileSettings/Hobbies}/List/styles.scss (80%) create mode 100644 src/shared/components/Settings/ProfileSettings/Hobbies/index.jsx rename src/shared/components/Settings/{Profile/Hobby => ProfileSettings/Hobbies}/styles.scss (93%) create mode 100644 src/shared/components/Settings/ProfileSettings/ImageInput/index.jsx create mode 100644 src/shared/components/Settings/ProfileSettings/ImageInput/styles.scss rename src/shared/components/Settings/{Profile/Education => ProfileSettings/Learning}/List/Item/index.jsx (98%) rename src/shared/components/Settings/{Profile/Education => ProfileSettings/Learning}/List/Item/styles.scss (99%) rename src/shared/components/Settings/{Profile/Education => ProfileSettings/Learning}/List/index.jsx (100%) rename src/shared/components/Settings/{Profile/Work => ProfileSettings/Learning}/List/styles.scss (80%) create mode 100644 src/shared/components/Settings/ProfileSettings/Learning/index.jsx rename src/shared/components/Settings/{Profile/Education => ProfileSettings/Learning}/styles.scss (83%) create mode 100644 src/shared/components/Settings/ProfileSettings/PersonalDetails/index.jsx create mode 100644 src/shared/components/Settings/ProfileSettings/index.jsx create mode 100644 src/shared/components/Settings/ProfileSettings/styles.scss create mode 100644 src/shared/components/Settings/SettingsBanner/index.jsx create mode 100644 src/shared/components/Settings/SettingsBanner/styles.scss create mode 100644 src/shared/components/Settings/TabSelector/index.jsx create mode 100644 src/shared/components/Settings/TabSelector/styles.scss diff --git a/__tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap b/__tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap index cbf30591eb..a44d0582cf 100644 --- a/__tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap +++ b/__tests__/shared/components/GUIKit/Datepicker/__snapshots__/index.jsx.snap @@ -102,7 +102,7 @@ exports[`Default render 1`] = ` regular={false} renderCalendarInfo={null} renderDayContents={[Function]} - renderMonthElement={null} + renderMonthElement={[Function]} renderMonthText={null} reopenPickerOnClearDate={false} required={false} diff --git a/__tests__/shared/components/Settings/Header/__snapshots__/index.jsx.snap b/__tests__/shared/components/Settings/Header/__snapshots__/index.jsx.snap index 606d5a7174..3c2f7e69ed 100644 --- a/__tests__/shared/components/Settings/Header/__snapshots__/index.jsx.snap +++ b/__tests__/shared/components/Settings/Header/__snapshots__/index.jsx.snap @@ -8,58 +8,33 @@ exports[`renders setting page header correctly 1`] = ` className="src-shared-components-Settings-Header-___styles__title___2Pmjv" >

- Settings + Profile Settings

- + + SAVE CHANGES + + `; diff --git a/__tests__/shared/components/Settings/Profile/AboutMe/__snapshots__/index.jsx.snap b/__tests__/shared/components/Settings/Profile/AboutMe/__snapshots__/index.jsx.snap deleted file mode 100644 index d263aed67b..0000000000 --- a/__tests__/shared/components/Settings/Profile/AboutMe/__snapshots__/index.jsx.snap +++ /dev/null @@ -1,1134 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`renders about me section of profile setting page correctly 1`] = ` -
-
-

- About Me -

-
- The most important information that other community members should know about you. -
-
-
-
-
- your profile image -
-
- User -
- - Change Image - - -
-
-
-
-
- Country to represent -
-