From b96be69502e5a0ba06352ea04c943f3ea173c0a5 Mon Sep 17 00:00:00 2001 From: Christian Wolf Date: Mon, 25 Jul 2022 16:04:00 +0200 Subject: [PATCH 1/3] Fix styling of recipe view When the instructions are longer than the side column, the side column should not be stretched vertically. Signed-off-by: Christian Wolf --- src/components/RecipeView.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/RecipeView.vue b/src/components/RecipeView.vue index 53d39a6a5..99286dc87 100644 --- a/src/components/RecipeView.vue +++ b/src/components/RecipeView.vue @@ -874,7 +874,7 @@ main { main { grid-column: 3/4; - grid-row: 1/4; + grid-row: 1/5; } @media screen and (max-width: 850px), print { From d933ff1100557f9c70970f8434c411504a1f2c7a Mon Sep 17 00:00:00 2001 From: Christian Wolf Date: Mon, 25 Jul 2022 16:21:22 +0200 Subject: [PATCH 2/3] Update changelog Signed-off-by: Christian Wolf --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4a88bcb5c..df16f1abc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,8 @@ [#1106](https://github.com/nextcloud/cookbook/pull/1106) @christianlupus - Make recipeYield optional [#1108](https://github.com/nextcloud/cookbook/pull/1108) @christianlupus +- Fix typos and styling issues + [#1112](https://github.com/nextcloud/cookbook/pull/1112) @christianlupus ### Maintenance - Add composer.json to version control to have unique installed dependency versions From 6f1eafa2cef24a659aa9ecbdf560d857335f73cc Mon Sep 17 00:00:00 2001 From: Christian Wolf Date: Mon, 25 Jul 2022 16:47:45 +0200 Subject: [PATCH 3/3] Fix some localizations Signed-off-by: Christian Wolf --- lib/Helper/Filter/JSON/FixRecipeYieldFilter.php | 10 +++++++--- src/components/RecipeEdit.vue | 3 ++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/lib/Helper/Filter/JSON/FixRecipeYieldFilter.php b/lib/Helper/Filter/JSON/FixRecipeYieldFilter.php index 0f6afc77f..d99f2091d 100644 --- a/lib/Helper/Filter/JSON/FixRecipeYieldFilter.php +++ b/lib/Helper/Filter/JSON/FixRecipeYieldFilter.php @@ -65,7 +65,7 @@ public function apply(array &$json): bool { // Heuristics: Array with multiple entries. // XXX How to parse an array correctly? - $this->logger->debug($this->l->t('Using heuristics to parse the recipeYield field of recipe {name}.', ['name' => $json['name']])); + $this->logger->debug($this->l->t('Using heuristics to parse the `recipeYield` field representing the number of servings of recipe {name}.', ['name' => $json['name']])); $json[self::YIELD] = join(' ', $json[self::YIELD]); } @@ -77,14 +77,18 @@ public function apply(array &$json): bool { sort($matches); $last = end($matches); - $this->logger->debug($this->l->t('Using the highest number found in recipeYield string. Totally found: {num}', ['num' => $count])); + $this->logger->debug($this->l->n( + 'Only a single number was found in the `recipeYield` field. Using it as number of servings.', + 'There are %n numbers found in the `recipeYield` field. Using the highest number found as number of servings.', + $count + )); $json[self::YIELD] = (int) $last; return true; } // We did not find anything useful. - $this->logger->info($this->l->t('Could not parse recipeYield field. Falling back to 1.')); + $this->logger->info($this->l->t('Could not parse `recipeYield` field. Falling back to 1 serving.')); $json[self::YIELD] = 1; return true; } diff --git a/src/components/RecipeEdit.vue b/src/components/RecipeEdit.vue index 91ff24432..13caf3c37 100644 --- a/src/components/RecipeEdit.vue +++ b/src/components/RecipeEdit.vue @@ -64,7 +64,8 @@