Skip to content

Commit

Permalink
Add final feedback (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
JannikStreek authored Dec 29, 2023
1 parent 55723a8 commit 0639846
Show file tree
Hide file tree
Showing 12 changed files with 24 additions and 41 deletions.
7 changes: 0 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,6 @@ name: Create and publish a Docker image
on:
release:
types: [published]
push:
branches: ["main"]
pull_request_target:
types:
- opened
branches:
- main

env:
REGISTRY: ghcr.io
Expand Down
2 changes: 1 addition & 1 deletion docker-compose-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ services:
# If you do not have another postgres database service in this docker-compose, you can add this postgres service.
# Note: Please use other credentials when using this in production.
postgres_prod:
image: postgres:12-alpine
image: postgres:15-alpine
# Pass config parameters to the postgres server.
# Find more information below when you need to generate the ssl-relevant file your self
# command: -c ssl=off -c ssl_cert_file=/var/lib/postgresql/server.crt -c ssl_key_file=/var/lib/postgresql/server.key
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ services:
SERVER_PORT: 8080
SERVER_HOST: 0.0.0.0
postgres:
image: postgres:12-alpine
image: postgres:15-alpine
environment:
PGDATA: /var/lib/postgresql/data/pgdata
# IMPORTANT: Do not use these credentials in production. Please use other credentials when deploying this in production
Expand Down
14 changes: 7 additions & 7 deletions frontend/compiled-lang/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"copy": "Kopieren",
"download": "Download",
"feedback.admin.header": "Feedback Chart",
"feedback.admin.header.subline": "Sammle Feedback und lasse es hier darstellen!",
"feedback.admin.header.subline": "Sammle Feedback und generiere eine Wortwolke!",
"feedback.admin.message.error": "Daten konnten nicht geladen werden.",
"feedback.admin.message.loading": "Lade...",
"feedback.user.button.submit": "Abschicken",
Expand All @@ -23,7 +23,7 @@
"languages.de": "Deutsch",
"languages.en": "Englisch",
"live.admin.header": "Live Text Chart",
"live.admin.header.subline": "Text eingeben, um die Anzahl sowie Kategorien der Wörter zu erkennen!",
"live.admin.header.subline": "Gestalte eine Wortwolke auf Basis eines Textes!",
"live.filter": "Filter",
"live.text.button.submit": "Text hinzufügen",
"live.text.loading": "Anfrage wird bearbeitet...",
Expand Down Expand Up @@ -57,21 +57,21 @@
"toolbar.buttons.dropdown.filter.pronoun": "Pronomen",
"toolbar.buttons.dropdown.filter.verb": "Verb",
"toolbar.buttons.dropdown.orientation.ninety": "Orientierung auf 90 Grad",
"toolbar.buttons.dropdown.orientation.zero": "Orientierung auf 0 Grad",
"toolbar.buttons.dropdown.orientation.zero": "Wörter waagerecht",
"toolbar.buttons.dropdown.theme.grammar": "Grammatik",
"toolbar.buttons.dropdown.theme.grey": "Grau",
"toolbar.buttons.dropdown.theme.mix": "Bunt",
"toolbar.buttons.dropdown.theme.grey": "grau",
"toolbar.buttons.dropdown.theme.mix": "bunt",
"toolbar.buttons.filter": "Filter",
"toolbar.buttons.orientation": "Orientierung",
"toolbar.buttons.settings": "Einstellungen",
"toolbar.buttons.share": "Teilen",
"toolbar.settings.language": "Sprache",
"toolbar.settings.rotation": "Limitiere Rotation auf 0°",
"toolbar.settings.rotation": "Wörter waagerecht",
"toolbar.settings.theme.adjective": "Adjektiv",
"toolbar.settings.theme.adverb": "Adverb",
"toolbar.settings.theme.article": "Artikel",
"toolbar.settings.theme.conjuncture": "Konjunktion",
"toolbar.settings.theme.explanation": "Bitte eine Farbe pro Kategorie auswählen",
"toolbar.settings.theme.explanation": "Wähle eine Farbe aus",
"toolbar.settings.theme.hint": "Die Farben werden genutzt, wenn der Filter auf 'Grammatik Kategorien' eingestellt ist.",
"toolbar.settings.theme.misc": "Sonstiges",
"toolbar.settings.theme.noun": "Nomen",
Expand Down
14 changes: 7 additions & 7 deletions frontend/lang/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"defaultMessage": "Feedback Chart"
},
"feedback.admin.header.subline": {
"defaultMessage": "Sammle Feedback und lasse es hier darstellen!"
"defaultMessage": "Sammle Feedback und generiere eine Wortwolke!"
},
"feedback.admin.message.error": {
"defaultMessage": "Daten konnten nicht geladen werden."
Expand Down Expand Up @@ -72,7 +72,7 @@
"defaultMessage": "Live Text Chart"
},
"live.admin.header.subline": {
"defaultMessage": "Text eingeben, um die Anzahl sowie Kategorien der Wörter zu erkennen!"
"defaultMessage": "Gestalte eine Wortwolke auf Basis eines Textes!"
},
"live.filter": {
"defaultMessage": "Filter"
Expand Down Expand Up @@ -171,16 +171,16 @@
"defaultMessage": "Orientierung auf 90 Grad"
},
"toolbar.buttons.dropdown.orientation.zero": {
"defaultMessage": "Orientierung auf 0 Grad"
"defaultMessage": "Wörter waagerecht"
},
"toolbar.buttons.dropdown.theme.grammar": {
"defaultMessage": "Grammatik"
},
"toolbar.buttons.dropdown.theme.grey": {
"defaultMessage": "Grau"
"defaultMessage": "grau"
},
"toolbar.buttons.dropdown.theme.mix": {
"defaultMessage": "Bunt"
"defaultMessage": "bunt"
},
"toolbar.buttons.filter": {
"defaultMessage": "Filter"
Expand All @@ -195,7 +195,7 @@
"defaultMessage": "Sprache"
},
"toolbar.settings.rotation": {
"defaultMessage": "Limitiere Rotation auf 0°"
"defaultMessage": "Wörter waagerecht"
},
"toolbar.settings.theme.article": {
"defaultMessage": "Artikel"
Expand Down Expand Up @@ -228,7 +228,7 @@
"defaultMessage": "Die Farben werden genutzt, wenn der Filter auf 'Grammatik Kategorien' eingestellt ist."
},
"toolbar.settings.theme.explanation": {
"defaultMessage": "Bitte eine Farbe pro Kategorie auswählen"
"defaultMessage": "Wähle eine Farbe aus"
},
"wordchart": {
"defaultMessage": "WordChart"
Expand Down
6 changes: 0 additions & 6 deletions frontend/src/feedback-chart/FeedbackChartAdminPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,6 @@ function FeedbackChartAdminPage({ words, reactWordchartSettingsFromServer, color
<div>
<Row className="content-header">
<Col>
<h1>
<FormattedMessage
id="feedback.admin.header"
defaultMessage="Feedback Chart"
/>
</h1>
<span>
<FormattedMessage
id="feedback.admin.header.subline"
Expand Down
6 changes: 0 additions & 6 deletions frontend/src/live-chart/LiveChartAdminPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,6 @@ function LiveChartAdminPage({ words, reactWordchartSettingsFromServer, filterFro
<div className="mt-2">
<div>
<Row >
<h1>
<FormattedMessage
id="live.admin.header"
defaultMessage="Live Text Chart"
/>
</h1>
<span>
<FormattedMessage
id="live.admin.header.subline"
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/live-chart/LiveChartSocketContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ function LiveChartSocketContainer(): React.ReactElement {
setCategoryColors(chart?.settings?.grammaticalCategoryColors ?? defaultGrammaticalCategoryColors)
setLanguage(chart.language ?? 'en')
})
.receive('error', (_resp) => { console.log('Unable to join') })
.receive('error', (_resp) => { console.error('Unable to join') })

channel.push('list_words', {})
.receive('ok', (newWordsFromServer: ServerWord[]) => {
Expand Down
4 changes: 3 additions & 1 deletion frontend/src/shared/components/AdminOptionToolbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,10 @@ export function AdminOptionToolbar({ id, adminId, language, filterFromServer, se

if (name === 'all') {
setWordFilter(ALL_CATEGORIES)
} else if (filterFromServer?.includes(name) === true) {
setWordFilter(filterFromServer.filter((e) => e !== name))
} else {
setWordFilter([name])
setWordFilter([...(filterFromServer ?? []), name])
}
}

Expand Down
2 changes: 1 addition & 1 deletion frontend/src/shared/components/CopyButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const CopyButton = ({ contentToCopy }: CopyProps): React.ReactElement =>
const copyUrl = async (): Promise<void> => {
if ('share' in (window.navigator)) {
await (window.navigator as any)?.share({
title: 'wordcharts',
title: 'WordCharts',
url: contentToCopy
})
} else if ('clipboard' in (window.navigator)) {
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/shared/components/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const Layout = ({ children }: { children: React.ReactNode }): React.ReactElement
<Navbar.Brand>
<a className="text-decoration-none fw-semibold" href="/" title="wordcharts">
<img src={wordchartsLogoUrl} className="d-inline-block align-text-top me-1" height="24" width="30" alt="wordcharts Logo" />
wordcharts
WordCharts
</a>
</Navbar.Brand>
<NavItem>
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/shared/defaultChartSettings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export const calculateMaxSize = (rotationAngles: MinMaxPair | undefined): number
}

export const defaultWordchartSettings: ReactWordcloudSettings = {
colors: ['#00456f'],
colors: [],
enableTooltip: true,
deterministic: true,
fontFamily: 'Fira Sans Extra Condensed',
Expand All @@ -42,7 +42,7 @@ export const defaultWordchartSettings: ReactWordcloudSettings = {
}

export const defaultGrammaticalCategoryColors: GrammaticalCategoryColors = {
verb: '#000000', adjective: '#000000', noun: '#000000', preposition: '#000000', default: '#000000', adverb: '#000000', pronoun: '#000000', article: '#000000', conjuncture: '#000000', misc: '#000000'
verb: '#A53139', adjective: '#0035DA', noun: '#000000', preposition: '#199463', default: '#666666', adverb: '#199463', pronoun: '#AD4AC6', article: '#3194E7', conjuncture: '#FFFF42', misc: '#666666'
}

export const defaultPaginationCount = 21

0 comments on commit 0639846

Please sign in to comment.