Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Oct 31, 2025

Processes want submission requesting browser support for hints on file upload fields to intelligently open file pickers in contextually appropriate folders (e.g., opening to Documents for resume uploads).

Changes

Want file

  • Created wants/180227d4-332e-4ded-93e0-8d587f8ab215.md with enhanced description and related specs
  • Tags: html, forms, api
  • Links to File API and HTML input specifications

YAML parser fixes (scripts/utils/frontmatter.mjs)

Fixed three bugs preventing proper frontmatter parsing:

  1. Array initialization: Arrays not created when first encountering list items without pre-initialization
  2. Indentation detection: Lines trimmed before checking indentation, breaking nested object property detection
  3. Object reuse: Same object reused across array items instead of creating new instances

Before:

tags:
  - html      # Lost - currentArray was null
  - forms     # Lost
related:
  - title: Spec
    url: https://example.com    # Lost - line trimmed before indentation check
    type: spec
  - title: Other  # Overwrote first object instead of creating new one

After: All structures parse correctly.

Performance improvements

  • Pre-compiled regex patterns moved outside parse loop
  • Extracted ensureArray() helper to reduce duplication

Closes #676

Original prompt

This section details on the original issue you should resolve

<issue_title>Upload hints for the web browser to open appropriate system folder in folder browser</issue_title>
<issue_description>---
title: Upload hints for the web browser to open appropriate system folder in folder browser
date: 2024-05-31T12:43:03.836Z
submitter: Tactile-Taco
number: 6659c5d76a7a79106f766b79
tags: [ ]
discussion: https://github.com/WebWeWant/webwewant.fyi/discussions/
status: [ discussing || in-progress || complete ]
related:

  • title:
    url:
    type: [ article || explainer || draft || spec || note || discussion ]

Navigating my filesystem every time I need to upload something to a website is a time-consuming pain. If upload fields provided some kind of hint about what file the user will upload to the website, the web browser could use that to open the file browser into what would likely be the appropriate folder containing said file. For example, when I need to upload my resume into a job application form, I click the button to upload my resume and the file browser opens into my home folder, from which I need to navigate to the folder to my career file before double-clicking my resume to upload. If the webpage provided a simple query for the appropriate file, the browser could likely guess that the 'career' folder or the folder that contains a file named 'resume' would be the appropriate folder to open the upload file browser into.


If posted, this will appear at https://webwewant.fyi/wants/6659c5d76a7a79106f766b79/</issue_description>

Comments on the Issue (you are @copilot in this section)

Note

Custom agent used: Wants Processor
Handle approved "Web We Want" submissions, produce wants, and keep issues ready for discussion conversion.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 3 commits October 31, 2025 16:57
Co-authored-by: aarongustafson <75736+aarongustafson@users.noreply.github.com>
- Created want file 180227d4-332e-4ded-93e0-8d587f8ab215.md
- Fixed YAML parser to handle array initialization
- Fixed YAML parser to preserve indentation for nested object detection
- Fixed YAML parser to create new objects for each array item

Co-authored-by: aarongustafson <75736+aarongustafson@users.noreply.github.com>
- Extract regex patterns outside loop for better performance
- Add helper function ensureArray() to reduce code duplication
- Use pre-compiled regex patterns throughout parser

Co-authored-by: aarongustafson <75736+aarongustafson@users.noreply.github.com>
Copilot AI changed the title [WIP] Add upload hints for web browser file selection Add want #676: Upload hints for intelligent file picker folder navigation Oct 31, 2025
Copilot AI requested a review from aarongustafson October 31, 2025 17:11
Copilot finished work on behalf of aarongustafson October 31, 2025 17:11
@aarongustafson aarongustafson marked this pull request as ready for review October 31, 2025 17:20
@aarongustafson aarongustafson merged commit 5511e1a into main Oct 31, 2025
5 checks passed
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.

Upload hints for the web browser to open appropriate system folder in folder browser

2 participants