Repository navigation
Description
WebKittens
Title of the proposal
Geolocation element (PEPC)
URL to the spec
In progress
URL to the spec's repository
No response
Issue Tracker URL
No response
Explainer URL
https://github.com/WICG/PEPC/blob/main/geolocation_explainer.md, https://github.com/WICG/PEPC/blob/main/explainer.md
TAG Design Review URL
No response
Mozilla standards-positions issue URL
No response
WebKit Bugzilla URL
No response
Radar URL
No response
Description
This is a separate request specifically just for the element which is part of the larger umbrella of the PEPC feature.
We have separated the "permission" element into separate elements (each focused on one capability) based on recent feedback and discussions. This position request is for the element, which focuses the "device location" capability, mirroring the getCurrentPosition or watchPosition APIs, while keeping the advantages of PEPC.
The element (with its existing attributes, events, and checks) will remain as the base common class for each of these elements, but would no longer be usable directly, therefore I've also included the old explainer for the permission element.
Relevant context:
Page Embedded Permission Control (PEPC) #270
Page Embedded Permission Control #908
Proposal for a element #59
Activity
annevk commentedon Sep 29, 2025
Thank you for filing this request! While overall we like building a slightly more declarative future, we found a number of issues with this proposal that we could not reconcile with the rest of the web platform:
appearance: baseeffort of making all HTML controls fully styleable by web developers.MinhAnhL commentedon Oct 1, 2025
Thanks for your feedback and questions, Anne!
This concern is reasonable. The proposal does impose a set of limitations on the ways in which the element can be styled, and developers might indeed find those limitations frustrating.
At core, the goal is to ensure that users see pixels that we believe provide meaningful context before we ask them to make a decision about a sensitive capability. Ideally, this will lead to better decision-making by users who are signaling intent to engage in the kind of decision we present. I think we're very open to alternatives, but the clearest way we've found to provide that assurance is to control the visibility and the content of the rendered element.
Are there particular limitations that you'd point to as being especially frustrating for developers? Could you perhaps help us gather feedback from folks on Apple's iOS team about their experience with similar constraints on controls like LocationButton? We'd love to learn from their experience.
Case studies from our origin trial of an earlier version of this proposal suggests that developers find this valuable.
Ideally, we wouldn't think of this as a one-off that's distinct from all other controls, but a pattern we'd like to extend across a broader spectrum of capabilities. As we develop those mechanisms and gain confidence in the pattern, it would be quite reasonable to introduce more friction for flows where we don't have the same strong signal of user interest and/or understanding. That seems like a good direction for the platform generally, and would allow us to generally be more opinionated when defending our users from distraction and abuse.
I think all browsers have developed heuristics in slightly different directions around permissions requests, forcing them to make a difficult trade-off. A browser can be stricter to protect users from spam, but this inevitably creates “false negatives” where legitimate requests are blocked. Conversely, a browser can be more lenient to ensure users can always grant a permission, but this comes at the direct costs of exposing users to more unwanted prompts.
This is precisely where our proposal offers a solution for the entire platform. By shifting towards a model that relies on a strong, user-initiated signal, we can break this fundamental trade-off. It allows a browser to be extremely opinionated in defending users from spammy, out of context requests., while still providing a clear and reliable path for users to grant permissions when they have clear intent. This is a better direction for the platform generally, reducing both user frustration and annoyance.
You're right that the current definition is somewhat implementation-defined. If more detail would be helpful for compatibility, that sounds like a great thing to collaborate on! Independent of the feature we're discussing here, it'd be fantastic to generally see more support for Intersection Observer v2. :)
annevk commentedon Oct 9, 2025
Not being able to style
<input type=file>in detail for instance. Over time that entire control became an API call essentially. And all the in-page pixels we used to have some control over got lost.And to be clear we get the bigger picture around this being a series of controls, but ultimately we think that is very large amount of complexity for a problem that can perhaps be addressed in different ways. As in, maybe we can make it clearer to end users in some manner what permission decisions they have made for a website and how to (partially) reset their current state for that website.
andypaicu commentedon Oct 24, 2025
Feedback from developers seemed to generally support that the current set of styles is sufficient. And we can always consider adding more allowed properties (for example WICG/PEPC#27 and WICG/PEPC#28).
<input type=file>was entirely restricted and it had a convenient circumvention method by respecting clicks on the label. I don't have the context on any of these decisions, but it seems natural to me that developers would want at least some styling options and we've accommodated for that.The value of a trusted signal of user intent seems to justify the complexity. It would allow significant reduction to unwanted permission prompt volume, and even removal/restrictions of existing APIs in favor of only allowing user-initiated usage. Additionally this is not necessarily limited to permissions, the concept of a trusted signal can go further (for example this early proposal of a "User Initiated PWA Installation" https://github.com/mikewest/pepc-install/).
annevk commentedon Nov 12, 2025
I wonder how this is supposed to interact with #403. Seems like this feature is either completely incompatible with that or it would make clickjacking a lot easier.
mikewest commentedon Nov 12, 2025
That's a good question, and I agree that it seems like embedding the element in a canvas is something we'd need to think about. I think we'd want to chat with the folks implementing that change to determine how things like occlusion detection would work in that context. If we can implement the same kinds of checks, then it seems fine. If not, then it would make that kind of embedding difficult.
Filed WICG/html-in-canvas#63.
mikewest commentedon Nov 18, 2025
Hey folks! We had a few conversations around this element, the broader story around elements in this category, and the concerns raised above at TPAC last week (see 1, 2, 3, etc). I wonder if y'all have drawn any new conclusions from those discussions? Any additional concerns? Any areas where your confidence has increased?
As an FYI, Mozilla has shifted their position in a more positive direction, and we're planning to push ahead with our implementation in Chromium, continuing to iterate with your feedback in mind.
Thanks!