Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PS-1830] Updated the autofill.js file to no longer add the 'data.com' attribute to tags #4001

Merged
merged 5 commits into from
Dec 16, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions apps/browser/src/content/autofill.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
9. Add new handler, for new command that responds with page details in response callback
10. Handle sandbox iframe and sandbox rule in CSP
11. Work on array of saved urls instead of just one to determine if we should autofill non-https sites
12. Remove setting of attribute com.browser.browser.userEdited on user-inputs
*/

function collect(document, undefined) {
Expand All @@ -50,11 +51,6 @@
// END MODIFICATION

document.elementsByOPID = {};
document.addEventListener('input', function (inputevent) {
inputevent.a !== false &&
inputevent.target.tagName.toLowerCase() === 'input' &&
(inputevent.target.dataset['com.bitwarden.browser.userEdited'] = 'yes');
}, true);

function getPageDetails(theDoc, oneShotId) {
// start helpers
Expand Down Expand Up @@ -279,8 +275,6 @@
addProp(field, 'title', getElementAttrValue(el, 'title'));

// START MODIFICATION
addProp(field, 'userEdited', !!el.dataset['com.browser.browser.userEdited']);

var elTagName = el.tagName.toLowerCase();
addProp(field, 'tagName', elTagName);

Expand Down