nextcloud / nextcloud/cookbook

Auto-detect times in steps to start timers

Open
#2,359 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement Frontend
Dominant language
HTML
Stars
641
Forks
113
Avg merge
21h 31m
Merged PRs (30d)
26

Description

Is your feature request related to a problem? Please describe.

In recipes times for cooking, baking, etc. is often mentioned within the text. Often one wants to run a timer for this (and not necessarily or only the cooking time defined for the whole recipe).

Describe the solution you'd like

If in a text a time is mentioned like, e.g.,

Pour in the noodles and cook for 7 minutes.

the time should be auto detected, visually highlighted, and clicking/tapping on 7 minutes should start a timer.

I am aware that this requires language-specific implementations. Therefore I propose to add the https://schema.org/inLanguage property to recipes. This would allow creating regexes for the specific languages, starting by the most common ones (i.e., English and the ones the developers know) and working the way through other languages via pull requests of devs proficient in the respective language.

An alternative to the language property or a fallback if it's not set is to try to automatically detect the language (1, 2, 3).

Describe alternatives you've considered

Manually define cooking time for single steps. This would most certainly require manual work for auto-imported recipes.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing how recipe step text is rendered and where timers are started; the issue names no files, tests, or entry points. Compare the proposed schema.org/inLanguage approach with the linked language-detection references. Done means recognized times are highlighted in recipe steps and selecting one starts the corresponding timer, with language handling defined.

Written by the indexing model from the issue text.

Assessment

Tech stack
html
Domain
frontend, internationalization
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.