Skip to content

Commit

Permalink
fix: #1096 (auth); (profile); dir / struct (up);
Browse files Browse the repository at this point in the history
  • Loading branch information
migbash committed Mar 9, 2023
1 parent c36817f commit 83258f8
Show file tree
Hide file tree
Showing 29 changed files with 28 additions and 125 deletions.
4 changes: 2 additions & 2 deletions src/lib/components/_main_/header/Header.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ COMPONENT JS - BASIC
import {
getUserLocation,
getUserLocationFromIP
} from '$lib/geoJs/init';
} from '$lib/geo-js/init';
import { dlog, dlogv2, NB_W_STY, NB_W_TAG, NB_W_TOG } from '$lib/utils/debug';
import arrow_down_fade from './assets/arrow-down-fade.svg';
import arrow_down from './assets/arrow-down.svg';
Expand All @@ -29,8 +29,8 @@ COMPONENT JS - BASIC
import profile_avatar from './assets/profile-avatar.svg';
import light_icon_theme from './assets/theme-light-icon.svg';
import type { GeoJsResponse } from '$lib/models/geojs-types';
import type { Cache_Single_Lang_Header_Translation_Response } from '$lib/models/_main_/navbar/types';
import type { GeoJsResponse } from '$lib/types/geojs-types';
import { db_firestore } from '$lib/firebase/init';
import { sessionStore } from '$lib/store/session';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
import LineupVectorTablet from './Lineup_Vector_Tablet.svelte';
import { REDIS_CACHE_LINEUPS_DATA_4 } from '$lib/graphql/fixtures/lineups/query';
import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { viewport_change } from '$lib/utils/platform-functions';
import no_visual from './assets/no_visual.svg';
import no_visual_dark from './assets/no_visual_dark.svg';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import { db_real } from '$lib/firebase/init';
import { get_odds } from '$lib/firebase/votes';
import { REDIS_CACHE_FIXTURE_PROBABILITIES_0 } from '$lib/graphql/fixtures/probabilities/query';
import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { userBetarenaSettings } from '$lib/store/user-settings';
import { getImageBgColor } from '$lib/utils/color_thief';
import {
Expand Down
2 changes: 1 addition & 1 deletion src/lib/components/page/fixture/votes/Vote_Widget.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
HASURA_FIXTURE_VOTES_DATA_0,
HASURA_FIXTURE_VOTES_INIT_UPDATE
} from '$lib/graphql/fixtures/votes/query';
import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { userBetarenaSettings } from '$lib/store/user-settings';
import {
fixtureVote,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
// [ℹ] external `exports` imports;
import { getTargetFixtureOdds } from '$lib/firebase/index';
import { db_real } from '$lib/firebase/init';
import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { UPDATE_MATCH_FIXTURE_VOTES } from '$lib/graphql/mutation';
import { userBetarenaSettings } from '$lib/store/user-settings';
import { fixtureVote } from '$lib/store/vote_fixture';
Expand Down
2 changes: 1 addition & 1 deletion src/lib/geoJs/init.ts → src/lib/geo-js/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/
import { get } from '$lib/api/utils';

import type { GeoJsResponse } from '$lib/models/geojs-types';
import type { GeoJsResponse } from '$lib/types/types.geojs';

export async function getUserLocation(): Promise<GeoJsResponse> {
const response = await get(
Expand Down
25 changes: 0 additions & 25 deletions src/lib/graphql/_main_/auth/query.ts

This file was deleted.

File renamed without changes.
18 changes: 0 additions & 18 deletions src/lib/graphql/profile/query.ts

This file was deleted.

27 changes: 0 additions & 27 deletions src/lib/models/_main_/auth/types.ts

This file was deleted.

27 changes: 0 additions & 27 deletions src/lib/models/profile/account-setting/types.ts

This file was deleted.

2 changes: 1 addition & 1 deletion src/lib/store/user-settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// ... contains the TRANSLATION LANG SELECTED by the USER;
// ... ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

import type { GeoJsResponse } from '$lib/models/geojs-types';
import type { GeoJsResponse } from '$lib/types/types.geojs';
import type { User } from 'firebase/auth';
import { writable } from 'svelte/store';

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { error } from '@sveltejs/kit';
import type { PageLoad } from './$types';

import type { GeoJsResponse } from '$lib/models/geojs-types';
import type {
REDIS_CACHE_SINGLE_fixtures_page_info_response,
REDIS_CACHE_SINGLE_general_countries_translation
} from '$lib/models/_main_/pages_and_seo/types';
import type { GeoJsResponse } from '$lib/types/types.geojs';
import { dlog, errlog, ERROR_CODE_INVALID, ERROR_CODE_PRELOAD, FIXTURE_PAGE_ERROR_MSG, PAGE_INVALID_MSG } from '$lib/utils/debug';

/** @type {import('./$types').PageLoad} */
Expand Down
6 changes: 3 additions & 3 deletions src/routes/api/hasura/_main_/auth/+server.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { json } from '@sveltejs/kit';
import { performance } from 'perf_hooks';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

import { BETARENA_SCORES_AUTH_TRANSLATION } from '$lib/graphql/_main_/auth/query';
import type { BETARENA_HASURA_auth_translations } from '$lib/models/hasura';
import type {
BETARENA_HASURA_auth_query,
REDIS_CACHE_SINGLE_auth_translation
BETARENA_HASURA_auth_query,
REDIS_CACHE_SINGLE_auth_translation
} from '$lib/models/_main_/auth/types';

// [ℹ] debug info
Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/about/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { ABT_F_get_target_fixture } from '@betarena/scores-lib/dist/functions/func.about.js';
import type { B_ABT_D } from '@betarena/scores-lib/types/about';

Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/content/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

import { CONT_F_get_target_fixture } from '@betarena/scores-lib/dist/functions/func.content.js';

Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/head-2-head/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

import { dev } from '$app/environment';

Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/incidents/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

import { INC_F_data_main, INC_F_generate_historic_fixtures_map, INC_F_get_target_fixture } from '@betarena/scores-lib/dist/functions/func.incidents.js';

Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/lineups/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

import { LIN_F_data_main, LIN_F_generate_historic_fixtures_map, LIN_F_generate_players_map, LIN_F_get_target_fixture, LIN_F_get_target_player_data } from '@betarena/scores-lib/dist/functions/func.lineups.js';

Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/probabilities/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

import { PR_F_get_target_fixture, PR_F_get_widget_translations, PR_F_translations_main } from '@betarena/scores-lib/dist/functions/func.probabilities.js';
import type { B_PR_T, PR_Fixture } from '@betarena/scores-lib/types/probabilities';
Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/scoreboard/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';


import { B_FS_compile_data, B_FS_generate_historic_fixtures_map, B_FS_generate_leagues_tournaments_map, B_FS_get_target_leagues, B_SF_get_target_fixture } from '@betarena/scores-lib/dist/functions/func.scoreboard.js';
Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/statistics/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { ST_F_data_main, ST_F_generate_historic_fixtures_map, ST_F_get_target_fixture } from '@betarena/scores-lib/dist/functions/func.statistics.js';

//#endregion ➤ Package Imports
Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/fixture/votes/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

import { VOT_F_data_main, VOT_F_get_target_fixture } from '@betarena/scores-lib/dist/functions/func.votes.js';

Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/home/livescores-v2/+server.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { generate_historic_fixtures_day_group_map, generate_leagues_map, generate_tournaments_map, get_target_date_fixtures, get_target_leagues } from '@betarena/scores-lib/dist/functions/func.livescores-v2.js';
import type { B_LS2_D, LS2_C_FixtureDateGroup } from '@betarena/scores-lib/types/livescores-v2';

Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/league/fixtures-odds/+server.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//#region ➤ Package Imports

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { json } from '@sveltejs/kit';

import {
Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/league/top-players/+server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { json } from '@sveltejs/kit';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { extract_playerId_and_teamId, generateTeamsAndPlayersMap, generate_top_players_data, getTargetSeasonPlayersInfo, get_target_teams_players_data } from '@betarena/scores-lib/dist/functions/func.top-players.js';
import type { TP_Season_Top_Player } from '@betarena/scores-lib/types/top-players';

Expand Down
6 changes: 3 additions & 3 deletions src/routes/api/hasura/profile/+server.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { json } from '@sveltejs/kit';
import { performance } from 'perf_hooks';

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';
import { SCORES_PROFILE_TRANSLATIONS_DATA_1 } from '$lib/graphql/profile/query';
import type {
BETARENA_HASURA_profile_query,
REDIS_CACHE_SINGLE_profile_translation
BETARENA_HASURA_profile_query,
REDIS_CACHE_SINGLE_profile_translation
} from '$lib/models/profile/account-setting/types';

// [ℹ] debug info
Expand Down
2 changes: 1 addition & 1 deletion src/routes/api/hasura/server._TEMPLATE_.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

//#region ➤ Package Imports

import { initGrapQLClient } from '$lib/graphql/init_graphQL';
import { initGrapQLClient } from '$lib/graphql/init';

//#endregion ➤ Package Imports

Expand Down

0 comments on commit 83258f8

Please sign in to comment.