Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Use human-readable duration inputs for signing request expiration settings

Chiusa
#8,714 1 commento 0 reazioni 1 assegnatario Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@Matheus-Imberio ci sta già lavorando.

Dal 26/9/2026.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
76/100
Tipo di issue
Funzionalità
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
javascript, typescript
Ambito
frontend

Direzione di ricerca

Start with RequestExpirationRuleEditor.vue, RenewalIntervalRuleEditor.vue, and model.ts to trace the existing expiration values and save flow. Read the matching tests before implementing the unit selection, exact conversion, validation, and enabled states. Run the relevant Vitest tests, then npm run lint, npm run stylelint, and npm run ts:check; done means values round-trip without changing the backend seconds format and initial render does not save.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement frontend good first issue javascript

Goal

Let administrators enter signing request durations with normal units instead of calculating raw seconds.

The backend and API must continue to store seconds.

UI

Use existing @nextcloud/vue components:

  • NcCheckboxRadioSwitch for enabled/disabled state;
  • NcTextField with type="number" for the amount;
  • NcSelect for the unit.

Example:

Enable request expiration

Expires after
[ 7 ] [ days ]

For access renewal:

Require access renewal

Renew access after
[ 24 ] [ hours ]

Units

Support:

  • seconds;
  • minutes;
  • hours;
  • days.

When loading an existing value, use the largest unit that represents the value exactly:

  • divisible by 86400 -> days;
  • else divisible by 3600 -> hours;
  • else divisible by 60 -> minutes;
  • else -> seconds.

Examples:

  • 300 -> 5 minutes
  • 3600 -> 1 hour
  • 86400 -> 1 day
  • 604800 -> 7 days
  • 61 -> 61 seconds

This rule is required so old values can be loaded and saved without data loss.

Save behavior

Convert the amount back to seconds before saving.

  • Disabled expiration stays 0.
  • Disabled renewal stays 0.
  • Do not save only because the component was opened.
  • Do not silently round a value.
  • Reject invalid, negative, non-finite, or unsafe numeric values.
  • The final seconds value must be a safe integer before it is sent.

Do not add a new maximum duration in the frontend. The backend policy remains the source of truth.

Main files

src/views/Settings/PolicyWorkbench/settings/expiration-rules/RequestExpirationRuleEditor.vue
src/views/Settings/PolicyWorkbench/settings/expiration-rules/RenewalIntervalRuleEditor.vue
src/views/Settings/PolicyWorkbench/settings/expiration-rules/model.ts

Update the matching tests.

Compatibility

Do not change:

  • policy keys;
  • API payload shape;
  • backend normalization;
  • stored seconds;
  • database or app config.

Target branch

main

Milestone: Next Major (36)

Tests

Cover:

  • every unit conversion;
  • largest exact unit selection;
  • exact round trips;
  • 61 seconds and other non-divisible values;
  • enabled and disabled states;
  • invalid and negative input;
  • overflow/unsafe integer input;
  • no save on initial render.

Run:

  • relevant Vitest tests;
  • npm run lint;
  • npm run stylelint;
  • npm run ts:check.

Done when

  • Common durations do not require manual seconds conversion.
  • Existing values round-trip without change.
  • Invalid values cannot produce a silent 0 or rounded value.
  • Backend/API contracts stay unchanged.
  • Tests pass.

Good first issue

The backend format is already defined. Keep this work inside the existing expiration editor, model, and tests.

Additional context
  • If you have questions, feel free to ask in this issue.
  • Give a ⭐️ star to this repository if you find LibreSign useful and would like to support the project.
  • You can also join our community: https://t.me/LibreSign
Lingua principale
PHP
Stelle
830
Fork
161
Merge medio
7h 3m
PR unite (30g)
488

Preparare l'ambiente

Apri in Codespaces

Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di LibreSign/libresign

Tutte le issue di LibreSign/libresign

Issue simili

Altre issue su PHP

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.