Skip to content

Commit

Permalink
head-title for compendium pages
Browse files Browse the repository at this point in the history
  • Loading branch information
userXinos committed Nov 8, 2023
1 parent 8dfcaac commit 1695b3f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/pages/CompendiumCorp.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<template>
<div>
<v-head><title>{{ title }}</title></v-head>

<CompendiumPage>
<div class="container">
<div
Expand Down Expand Up @@ -136,10 +138,12 @@
<script setup lang="ts">
import { CorpData, CorpMember, getTechIndex } from 'bot_client';
import { onMounted, reactive, Ref, ref, watch } from 'vue';
import { useI18n } from 'vue-i18n';
import { getDiscordAvatarUrl } from '../utils/getDiscordUrl';
import client from '../utils/compendium';
import { Head as VHead } from '@vueuse/head';
import Modal, { SIZES } from '@/components/Modal.vue';
import Icon from '@/components/Icon.vue';
import TechList from '@/components/CompendiumTechList.vue';
Expand All @@ -152,6 +156,7 @@ import modulesData from '@Data/modules.js';
import objectArrayify from '../utils/objectArrayify';
import { getTechFromIndex } from 'bot_client/src/module_types';
const DISPLAY_USER_TECH_ITEMS = 5;
const MAX_ITEMS_PAGE = 50;
Expand All @@ -163,6 +168,8 @@ interface UserInfo {
}
}
const { t } = useI18n();
const title = t('HS_COMPENDIUM');
const { hourCycles } = new Intl.Locale(navigator.language);
const isBrowserLocale24h = hourCycles ? ['h23', 'h24'].some((hourCycle) => hourCycles.includes(hourCycle)) : true;
Expand Down Expand Up @@ -323,6 +330,7 @@ function getTechForDisplay(member: CorpMember): Record<string, {level: number|st
@import "../style/vars";
@import "../style/userInput";
@import "../style/CompendiumTechList";
@import "../style/page";
.container {
max-width: 680px;
Expand Down
4 changes: 4 additions & 0 deletions src/pages/CompendiumTech.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<template>
<CompendiumPage>
<v-head><title>{{ title }}</title></v-head>

<div>

<div class="container">
Expand Down Expand Up @@ -49,6 +51,7 @@ import { getTechIndex, TechLevels } from 'bot_client';
import client from '../utils/compendium';
import debounce from 'lodash.debounce';
import { Head as VHead } from '@vueuse/head';
import Icon from '@/components/Icon.vue';
import Modal, { SIZES } from '@/components/Modal.vue';
import CompendiumPage from '../components/CompendiumPage.vue';
Expand Down Expand Up @@ -86,6 +89,7 @@ const minLvl: Record<string, number> = Object.fromEntries([
const setTechLevel: SetTechLevel = debounce((...args) => client.setTechLevel(...args), 500);
const { t } = useI18n();
const title = t('HS_COMPENDIUM');
const openModal = ref(false);
const data = ref<TechLevels>(null);
const levelMap = ref<Record<string, number>>({});
Expand Down

0 comments on commit 1695b3f

Please sign in to comment.