Skip to content

Commit 5c524d7

Browse files
fgravinjahow
authored andcommitted
geocat: adapt UI to geocat mockups
add TW safelist for title layout Change title of app (#22)
1 parent d7fb220 commit 5c524d7

File tree

7 files changed

+24
-10
lines changed

7 files changed

+24
-10
lines changed

apps/datahub/src/app/home/navigation-menu/navigation-menu.component.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
? 'decoration-primary'
77
: 'decoration-transparent hover:decoration-primary transition-colors'
88
"
9-
class="hidden sm:block sm:py-4 uppercase truncate underline decoration-4 underline-offset-[19px]"
9+
class="hidden sm:block sm:py-4 uppercase truncate font-title text-sm underline decoration-4 underline-offset-[19px]"
1010
[style.color]="foregroundColor"
1111
translate
1212
>

apps/datahub/src/app/home/navigation-menu/navigation-menu.component.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import {
99
ROUTER_ROUTE_NEWS,
1010
ROUTER_ROUTE_ORGANIZATIONS,
1111
} from '../../router/constants'
12-
import { getThemeConfig } from '@geonetwork-ui/util/app-config'
12+
// import { getThemeConfig } from '@geonetwork-ui/util/app-config'
1313

1414
marker('datahub.header.news')
1515
marker('datahub.header.datasets')
@@ -21,7 +21,7 @@ marker('datahub.header.organizations')
2121
changeDetection: ChangeDetectionStrategy.OnPush,
2222
})
2323
export class NavigationMenuComponent {
24-
foregroundColor = getThemeConfig().HEADER_FOREGROUND_COLOR || '#ffffff'
24+
foregroundColor = /*getThemeConfig().HEADER_FOREGROUND_COLOR ||*/ '#ffffff'
2525
displayMobileMenu = false
2626
tabLinks = [
2727
{

apps/datahub/src/app/record/header-record/header-record.component.html

+5-4
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
[label]="'datahub.search.back' | translate"
1010
[icon]="'matArrowBack'"
1111
[style.--navigation-button-color]="foregroundColor"
12+
[style.--color-background]="'#ffffff'"
1213
>
1314
</gn-ui-navigation-button>
1415
</div>
@@ -17,19 +18,19 @@
1718
*ngIf="metadata?.uniqueIdentifier"
1819
[record]="metadata"
1920
[displayCount]="false"
20-
class="flex text-background content-center"
21+
class="flex text-background content-center bg-white rounded px-2 items-center justify-center font-semibold text-sm leading-5"
2122
[style.color]="foregroundColor"
2223
[style.--star-toggle-enabled-color]="foregroundColor"
2324
[style.--star-toggle-disabled-color]="foregroundColor"
2425
></gn-ui-favorite-star>
25-
<gn-ui-language-switcher
26+
<!-- <gn-ui-language-switcher
2627
*ngIf="showLanguageSwitcher"
2728
class="language-switcher text-[13px] mt-0.5"
2829
[style.--color-main]="foregroundColor"
2930
[style.--color-gray-300]="foregroundColor"
3031
[style.--color-primary-darker]="foregroundColor"
3132
[style.--color-primary-black]="foregroundColor"
32-
></gn-ui-language-switcher>
33+
></gn-ui-language-switcher> -->
3334
</div>
3435
</div>
3536
<div
@@ -41,7 +42,7 @@
4142
</div>
4243
<div
4344
class="flex flex-row flex-wrap items-center gap-4 mb-4 ml-4 sm:mr-[332px]"
44-
[style.color]="foregroundColor"
45+
[style.color]="'#ffffff'"
4546
>
4647
<gn-ui-badge
4748
*ngIf="(isGeodata$ | async) === true"

apps/datahub/src/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<html lang="en" class="overflow-y-scroll">
33
<head>
44
<meta charset="utf-8" />
5-
<title>Datahub</title>
5+
<title>geocat.ch</title>
66
<base href="/" />
77
<meta name="viewport" content="width=device-width, initial-scale=1" />
88
<link rel="stylesheet" href="assets/css/materials-symbols-outline.css" />

apps/datahub/tailwind.config.js

+8
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@ const { join } = require('path')
44

55
module.exports = {
66
...baseConfig,
7+
safelist: [
8+
...baseConfig.safelist,
9+
'w-max',
10+
'items-end',
11+
'sm:h-36',
12+
'md:h-[10.5rem]',
13+
'h-20',
14+
],
715
theme: {
816
...baseConfig.theme,
917
extend: {

libs/ui/inputs/src/lib/navigation-button/navigation-button.component.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<button
2-
class="group flex items-center justify-center gap-1 backdrop-blur p-1 bg-primary-opacity-30 rounded content-center"
2+
class="bg-white text-xs font-semibold group flex items-center justify-center gap-1 backdrop-blur py-1.5 px-2 bg-primary-opacity-30 rounded content-center"
33
>
4-
<ng-icon [name]="icon" class="align-middle w-[18px]"></ng-icon>
4+
<ng-icon [name]="icon" class="align-middle w-[18px] text-primary"></ng-icon>
55
<span
66
class="mx-2 mt-0.5 text-[16px] tracking-widest content-center opacity-75"
77
>{{ label.toUpperCase() }}</span

tailwind.base.config.js

+5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
module.exports = {
2+
safelist: [],
23
theme: {
34
extend: {
45
colors: {
@@ -53,6 +54,10 @@ module.exports = {
5354
'var(--font-family-title, ui-serif, Georgia, Cambria, "Times New Roman", Times, serif)', // alias for serif
5455
mono: 'ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',
5556
},
57+
// specific for geocat
58+
fontWeight: {
59+
title: '600',
60+
},
5661
fontSize: {
5762
13: '13px',
5863
21: [

0 commit comments

Comments
 (0)