Skip to content

Commit 64b690d

Browse files
Merge branch 'main' into jkt/css-asana
2 parents 9e9c59c + c2dd617 commit 64b690d

File tree

129 files changed

+2648
-1247
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

129 files changed

+2648
-1247
lines changed

.github/scripts/diff-directories.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function upperCaseFirstLetter(string) {
2626
return string.charAt(0).toUpperCase() + string.slice(1);
2727
}
2828

29-
function displayDiffs(dir1Files, dir2Files, isOpen) {
29+
function displayDiffs(dir1Files, dir2Files) {
3030
const rollupGrouping = {};
3131
/**
3232
* Rolls up multiple files with the same diff into a single entry
@@ -79,13 +79,13 @@ function displayDiffs(dir1Files, dir2Files, isOpen) {
7979
}
8080
}
8181
outString += '\n\n' + rollup.string;
82-
return renderDetails(title, outString, isOpen);
82+
return renderDetails(title, outString);
8383
})
8484
.join('\n');
8585
return outString;
8686
}
8787

88-
function renderDetails(section, text, isOpen) {
88+
function renderDetails(section, text) {
8989
if (section === 'dist') {
9090
section = 'apple';
9191
}
@@ -120,5 +120,5 @@ sortFiles(readFilesRecursively(dir1 + sourcesOutput), 'dir1');
120120
sortFiles(readFilesRecursively(dir2 + sourcesOutput), 'dir2');
121121

122122
// console.log(Object.keys(files))
123-
const fileOut = displayDiffs(sections.dir1, sections.dir2, true);
123+
const fileOut = displayDiffs(sections.dir1, sections.dir2);
124124
console.log(fileOut);

CODEOWNERS

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ injected/src/features/autofill-password-import.js @duckduckgo/content-scope-scri
1515
Sources/ @duckduckgo/content-scope-scripts-owners @duckduckgo/apple-devs
1616
injected/entry-points/android.js @duckduckgo/content-scope-scripts-owners @duckduckgo/android-devs
1717
injected/entry-points/extension-mv3.js @duckduckgo/content-scope-scripts-owners @kzar @sammacbeth
18-
injected/entry-points/chrome.js @duckduckgo/content-scope-scripts-owners @kzar @sammacbeth
1918
injected/entry-points/windows.js @duckduckgo/content-scope-scripts-owners @duckduckgo/team-windows-development
2019

2120
# Test owners

eslint.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export default tseslint.config(
1111
'**/build/',
1212
'**/docs/',
1313
'injected/lib',
14+
'injected/playwright-report/',
1415
'Sources/ContentScopeScripts/dist/',
1516
'injected/integration-test/extension/contentScope.js',
1617
'injected/integration-test/test-pages/duckplayer/scripts/dist',

injected/docs/favicon.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
title: Favicon Monitor
3+
---
4+
5+
# Favicon Monitor
6+
7+
Reports the presence of favicons on page-load, and optionally when they change.
8+
9+
## Notifications
10+
11+
### `faviconFound`
12+
- {@link "Favicon Messages".FaviconFoundNotification}
13+
- Sent on page load, sends {@link "Favicon Messages".FaviconFound}
14+
15+
**Example**
16+
17+
```json
18+
{
19+
"favicons": [
20+
{
21+
"href": "favicon.png",
22+
"rel": "stylesheet"
23+
}
24+
],
25+
"documentUrl": "https://example.com"
26+
}
27+
```
28+
29+
## Remote Config
30+
31+
## Enabled (default)
32+
{@includeCode ../integration-test/test-pages/favicon/config/favicon-enabled.json}
33+
34+
### Disable the monitor only.
35+
36+
To only receive the initial payload and nothing more (to mimic the old behavior),
37+
you can set `monitor: false` in the remote config, and it will not install the Mutation Observer.
38+
39+
{@includeCode ../integration-test/test-pages/favicon/config/favicon-monitor-disabled.json}

injected/entry-points/android.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* @module Android integration
33
*/
44
import { load, init } from '../src/content-scope-features.js';
5-
import { processConfig, isGloballyDisabled } from './../src/utils';
5+
import { processConfig } from './../src/utils';
66
import { AndroidMessagingConfig } from '../../messaging/index.js';
77

88
function initCode() {
@@ -14,9 +14,6 @@ function initCode() {
1414
const userPreferences = $USER_PREFERENCES$;
1515

1616
const processedConfig = processConfig(config, userUnprotectedDomains, userPreferences);
17-
if (isGloballyDisabled(processedConfig)) {
18-
return;
19-
}
2017

2118
const configConstruct = processedConfig;
2219
const messageCallback = configConstruct.messageCallback;

injected/entry-points/apple.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* @module Apple integration
33
*/
44
import { load, init } from '../src/content-scope-features.js';
5-
import { processConfig, isGloballyDisabled, platformSpecificFeatures } from './../src/utils';
5+
import { processConfig, platformSpecificFeatures } from './../src/utils';
66
import { WebkitMessagingConfig, TestTransportConfig } from '../../messaging/index.js';
77

88
function initCode() {
@@ -15,10 +15,6 @@ function initCode() {
1515

1616
const processedConfig = processConfig(config, userUnprotectedDomains, userPreferences, platformSpecificFeatures);
1717

18-
if (isGloballyDisabled(processedConfig)) {
19-
return;
20-
}
21-
2218
if (import.meta.injectName === 'apple-isolated') {
2319
processedConfig.messagingConfig = new WebkitMessagingConfig({
2420
webkitMessageHandlerNames: ['contentScopeScriptsIsolated'],

injected/entry-points/chrome.js

Lines changed: 0 additions & 165 deletions
This file was deleted.

injected/entry-points/integration.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,14 @@ function generateConfig() {
2626
domain: topLevelUrl.hostname,
2727
isBroken: false,
2828
allowlisted: false,
29-
enabledFeatures: ['fingerprintingCanvas', 'fingerprintingScreenSize', 'navigatorInterface', 'cookie'],
29+
enabledFeatures: [
30+
'fingerprintingCanvas',
31+
'fingerprintingScreenSize',
32+
'navigatorInterface',
33+
'cookie',
34+
'webCompat',
35+
'apiManipulation',
36+
],
3037
},
3138
};
3239
}

injected/entry-points/windows.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* @module Windows integration
33
*/
44
import { load, init } from '../src/content-scope-features.js';
5-
import { processConfig, isGloballyDisabled, platformSpecificFeatures } from './../src/utils';
5+
import { processConfig, platformSpecificFeatures } from './../src/utils';
66
import { WindowsMessagingConfig } from '../../messaging/index.js';
77

88
function initCode() {
@@ -14,9 +14,7 @@ function initCode() {
1414
const userPreferences = $USER_PREFERENCES$;
1515

1616
const processedConfig = processConfig(config, userUnprotectedDomains, userPreferences, platformSpecificFeatures);
17-
if (isGloballyDisabled(processedConfig)) {
18-
return;
19-
}
17+
2018
processedConfig.messagingConfig = new WindowsMessagingConfig({
2119
methods: {
2220
// @ts-expect-error - Type 'unknown' is not assignable to type...

0 commit comments

Comments
 (0)