From bf595729574eb266c563d31f7448e2d332e24ca0 Mon Sep 17 00:00:00 2001 From: lunarkid <4476442+dedywahyudi@users.noreply.github.com> Date: Thu, 15 Sep 2022 20:36:06 +0700 Subject: [PATCH 1/3] fix: skills on prod --- .../WorkSkills/Skills/AddSkillsModal/index.jsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx b/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx index e7fa312d4d..25ee68a745 100755 --- a/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx +++ b/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx @@ -26,10 +26,15 @@ export default function AddSkillsModal({ onSave, setEditingSkills, }) { + let category; const [tempStr, setTempStr] = React.useState(''); const [tab, setTab] = React.useState(intialCategory); const [displayingSkills, setDisplayingSkills] = React.useState([]); - const category = tab; + if (process.env.NODE_ENV === 'production') { + category = tab.toUpperCase(); + } else { + category = tab; + } // onInit React.useEffect(() => { From 3e2d1c0461775e6191da1df1c407b27a985a6a13 Mon Sep 17 00:00:00 2001 From: lunarkid <4476442+dedywahyudi@users.noreply.github.com> Date: Fri, 16 Sep 2022 10:09:31 +0700 Subject: [PATCH 2/3] ci: set to staging --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index dc0af6bea9..545ddced33 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -379,6 +379,7 @@ workflows: only: - develop - old-mm-fix + - reskin-profile-settings # Production builds are exectuted # when PR is merged to the master # Don't change anything in this configuration From 7fa27b6db975aaf84e1b112df949bbe404b66e87 Mon Sep 17 00:00:00 2001 From: lunarkid <4476442+dedywahyudi@users.noreply.github.com> Date: Tue, 20 Sep 2022 11:18:54 +0700 Subject: [PATCH 3/3] fix: dev & prod loading skills --- .../WorkSkills/Skills/AddSkillsModal/index.jsx | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx b/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx index 25ee68a745..357a115b92 100755 --- a/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx +++ b/src/shared/components/Settings/ExperienceAndSkills/WorkSkills/Skills/AddSkillsModal/index.jsx @@ -26,15 +26,10 @@ export default function AddSkillsModal({ onSave, setEditingSkills, }) { - let category; const [tempStr, setTempStr] = React.useState(''); const [tab, setTab] = React.useState(intialCategory); const [displayingSkills, setDisplayingSkills] = React.useState([]); - if (process.env.NODE_ENV === 'production') { - category = tab.toUpperCase(); - } else { - category = tab; - } + const category = tab; // onInit React.useEffect(() => { @@ -42,7 +37,7 @@ export default function AddSkillsModal({ setDisplayingSkills([...userSkills]); }, [userSkills]); - const find = (arr, i) => arr && arr.indexOf(i) !== -1; + const find = (arr, i) => arr && _.findIndex(arr, e => e.toLowerCase() === i.toLowerCase()) !== -1; const findSkill = (arr, skill) => arr && arr.find(a => a.id === skill.id); const popularSkills = React.useMemo(() => allSkills