Skip to content

Commit

Permalink
Merge pull request #539 from UTNkar/feat/miljogruppentheme
Browse files Browse the repository at this point in the history
Theme added
  • Loading branch information
robindymer committed Oct 6, 2023
2 parents ad77988 + c54a55e commit ef1fd1d
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions backend/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,7 @@ class ThemesEnum(models.TextChoices):
KLUBBVERKET = 'klubbverket', 'Klubbverket'
FORSRANNINGEN = 'forsranningen', 'Forsränningen'
REBUSRALLYT = 'rebusrallyt', 'Rebusrallyt'
MILJOGRUPPEN = 'miljogruppen', 'Miljögruppen'

id = models.AutoField(primary_key=True)
name = models.CharField(
Expand Down
1 change: 1 addition & 0 deletions frontend/src/@types/Database.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export enum OrganisationTheme {
KLUBBVERKET = 'klubbverket',
FORSRANNINGEN = 'forsranningen',
REBUSRALLYT = 'rebusrallyt',
MILJOGRUPPEN = 'miljogruppen',
}

export interface Organisation {
Expand Down
Binary file added frontend/src/assets/images/miljogruppen.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions frontend/src/components/Header/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import TdLogo from '../../assets/images/td.png';
import KlubbverketLogo from '../../assets/images/klubbverket.png';
import ForsranningenLogo from '../../assets/images/forsranningen.png';
import RebusrallytLogo from '../../assets/images/rebusrallyt.png';
import MiljogruppenLogo from '../../assets/images/miljogruppen.png';

import { OrganisationTheme } from '../../@types';

Expand All @@ -35,6 +36,7 @@ const THEME_TO_IMAGE = Object.freeze({
[OrganisationTheme.KLUBBVERKET]: KlubbverketLogo,
[OrganisationTheme.FORSRANNINGEN]: ForsranningenLogo,
[OrganisationTheme.REBUSRALLYT]: RebusrallytLogo,
[OrganisationTheme.MILJOGRUPPEN]: MiljogruppenLogo,
});

interface HeaderProps {
Expand Down
12 changes: 12 additions & 0 deletions frontend/src/utils/themes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,4 +130,16 @@ export const themes = {
},
},
})),
[OrganisationTheme.MILJOGRUPPEN]: responsiveFontSizes(createTheme({
typography,
palette: {
...paletteBase,
primary: {
main: '#8ac163',
dark: '#4a8a1d',
light: '#a2c987',
contrastText: '#fff',
},
},
})),
};

0 comments on commit ef1fd1d

Please sign in to comment.