feat(v4): Update the help center portal design (#10296)

Co-authored-by: Pranav <pranavrajs@gmail.com>
This commit is contained in:
Sivin Varghese
2024-10-24 10:39:36 +05:30
committed by GitHub
parent 6d3ecfe3c1
commit a3855a8d1d
144 changed files with 6376 additions and 6604 deletions

View File

@@ -110,4 +110,10 @@ export const actions = {
updatePortal: async ({ commit }, portal) => {
commit(types.UPDATE_PORTAL_ENTRY, portal);
},
switchPortal: async ({ commit }, isSwitching) => {
commit(types.SET_PORTAL_SWITCHING_FLAG, {
isSwitching,
});
},
};

View File

@@ -6,6 +6,8 @@ export const getters = {
},
isFetchingPortals: state => state.uiFlags.isFetching,
isCreatingPortal: state => state.uiFlags.isCreating,
isSwitchingPortal: state => state.uiFlags.isSwitching,
portalBySlug:
(...getterArguments) =>
portalId => {
@@ -23,4 +25,5 @@ export const getters = {
},
count: state => state.portals.allIds.length || 0,
getMeta: state => state.meta,
isSwitching: state => state.isSwitching,
};

View File

@@ -31,6 +31,7 @@ const state = {
uiFlags: {
allFetched: false,
isFetching: false,
isSwitching: false,
},
};

View File

@@ -12,6 +12,7 @@ export const types = {
REMOVE_PORTAL_ENTRY: 'removePortalEntry',
REMOVE_PORTAL_ID: 'removePortalId',
SET_HELP_PORTAL_UI_FLAG: 'setHelpCenterUIFlag',
SET_PORTAL_SWITCHING_FLAG: 'setPortalSwitchingFlag',
};
export const mutations = {
@@ -105,4 +106,8 @@ export const mutations = {
},
};
},
[types.SET_PORTAL_SWITCHING_FLAG]($state, { isSwitching }) {
$state.uiFlags.isSwitching = isSwitching;
},
};