Skip to content

Add 'Expires' to genform, using bulma-calendar - #50

Closed
joker314 wants to merge 1 commit into
securitytxt:masterfrom
joker314:feat/add-expires
Closed

joker314 wants to merge 1 commit into
securitytxt:masterfrom
joker314:feat/add-expires

Conversation

@joker314

@joker314 joker314 commented Sep 18, 2020

Copy link
Copy Markdown
Contributor

Closes #41

Here is a picture of the new entry into the generation form. It doesn't look too different to the other inputs, which I think is quite nice:

An inputbox with a calendar icon to the left, and an example date and time already inputted. The box is titled 'Expires' and has a short description which reads 'The date and time when the content of the security.txt file should be considered stale (so security researchers should then not trust it). Make sure you update this value periodcally and keep your file under review. See the full description of Expires'

In theory, this PR could be merged now and the functionality is all there. But first I want to go through and fix stuff up:

  • consider using Intl JS API for formatting dates
  • decide how to handle timezones
  • remove the 'Validate' button in the calendar which causes the form to prematurely submit
  • investigate accessibility (especially keyboard accessibility) with the calendar. This Bulma extension is incredibly useful but e.g. tabbing into it seems to not be obvious
  • code cleanup: make 'Expires' less of a special case
  • in the defaults.html, add a comment just for the Bulma extension bit
  • consider using the JS file with all the bulma extensions, since a future PR will be using the form validation one too
  • there's a typo in the description for 'Expires' (periodically is misspelled)

@joker314

Copy link
Copy Markdown
Contributor Author

Let's redo this with <input type="date"> together with a <input type="time">. Using "datetime" or even "datetime-locale" could be bad for browser support (Firefox 👀)

@joker314 joker314 closed this Sep 19, 2020
@joker314
joker314 deleted the feat/add-expires branch September 19, 2020 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

New field: Expires

1 participant