Skip to content

Commit

Permalink
Fix/2620 data tab font size (#2621)
Browse files Browse the repository at this point in the history
* fix: changed default font size to 16px in data tab at /maps page

* fix: changed font size to 16px in data page
  • Loading branch information
JinIgarashi authored Jan 3, 2024
1 parent b70014a commit 6c77e3c
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 19 deletions.
5 changes: 5 additions & 0 deletions .changeset/rotten-pigs-arrive.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"geohub": patch
---

fix: changed default font size to 16px in data tab at /maps page
Original file line number Diff line number Diff line change
Expand Up @@ -295,8 +295,8 @@
open={true}
placeholder="Type keywords to explore datasets..."
on:change={handleFilterInput}
iconSize={24}
fontSize={4}
iconSize={20}
fontSize={6}
timeout={SearchDebounceTime}
disabled={isLoading}
loading={isLoading}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import type { Breadcrumb } from '@undp-data/svelte-undp-design';
export let category: Breadcrumb;
export let size: 'small' | 'medium' = 'medium';
const handleClick = () => {
dispatch('clicked');
Expand All @@ -21,7 +20,7 @@
on:click={handleClick}
on:keydown={handleEnterKey}
>
<figure class="category image center {size === 'medium' ? 'is-64x64' : 'is-48x48'}">
<figure class="category image center is-64x64">
{#if category.icon.startsWith('fa')}
<i class="{category.icon} fa-4x" />
{:else if category.icon.startsWith('fi')}
Expand All @@ -31,11 +30,7 @@
{/if}
</figure>
{#if category.name}
<p
class="category {`${
size === 'medium' ? 'title is-5' : 'subtitle is-6 '
}`} center pt-2 has-text-weight-bold"
>
<p class="category title is-6 center pt-2 has-text-weight-semibold">
{category.name}
</p>
{/if}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
const dispatch = createEventDispatcher();
export let categories: Breadcrumb[];
export let cardSize: 'medium' | 'small' = 'medium';
export let breadcrumbs: Breadcrumb[];
onMount(async () => {
Expand Down Expand Up @@ -36,12 +35,11 @@

<div
class="container mt-2 category-container"
style="grid-template-columns: repeat(auto-fit, minmax({cardSize === 'medium' ? 80 : 70}px, 1fr))"
style="grid-template-columns: repeat(auto-fit, minmax(80px, 1fr))"
>
{#each categories as category}
<DataCategoryCard
bind:category
size={cardSize}
on:clicked={() => {
getSelectedCategory(category);
}}
Expand Down
3 changes: 1 addition & 2 deletions sites/geohub/src/components/pages/map/data/DataView.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@
/>

<div class="my-2 ml-1 mr-2">
<nav class="breadcrumb has-text-weight-bold is-medium" aria-label="breadcrumbs">
<nav class="breadcrumb has-text-weight-bold" aria-label="breadcrumbs">
<ul>
{#each breadcrumbs as page, index}
<li class={index === breadcrumbs.length - 1 ? 'is-active' : ''}>
Expand Down Expand Up @@ -270,7 +270,6 @@
{:else if dataCategories}
<DataCategoryCardList
categories={dataCategories}
cardSize="medium"
on:selected={handleCategorySelected}
bind:breadcrumbs
/>
Expand Down
8 changes: 4 additions & 4 deletions sites/geohub/src/components/pages/map/data/TextFilter.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,8 @@
/>
</div>

<PanelButton icon="fas fa-arrow-down-short-wide fa-xl" tooltip="Sort" {disabled} width="200px">
<p class="title is-5 m-0 p-0 pb-2">Sort settings</p>
<PanelButton icon="fas fa-arrow-down-short-wide fa-lg" tooltip="Sort" {disabled} width="200px">
<p class="is-size-6 has-text-weight-semibold m-0 p-0 pb-2">Sort settings</p>

<Radios
radios={DatasetSortingColumns}
Expand All @@ -132,8 +132,8 @@
/>
</PanelButton>

<PanelButton icon="fas fa-gear fa-xl" tooltip="Settings" position="left" {disabled} width="230px">
<p class="title is-5 m-0 p-0">Search settings</p>
<PanelButton icon="fas fa-gear fa-lg" tooltip="Settings" {disabled} width="230px">
<p class="is-size-6 has-text-weight-semibold m-0 p-0">Search settings</p>
<p class="subtitle is-6 pb-0 pt-2 my-1">Text search</p>

<Radios
Expand Down
2 changes: 1 addition & 1 deletion sites/geohub/src/routes/(app)/data/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
</script>

{#if data.session}
<div class="tabs is-fullwidth is-medium data-tabs">
<div class="tabs is-fullwidth data-tabs">
<ul>
{#each tabs as tab}
<li class={activeTab === tab.label ? 'is-active' : ''}>
Expand Down

0 comments on commit 6c77e3c

Please sign in to comment.