From cdd34c2a524bfb0d2f11178006e46c8658aeadd4 Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Mon, 18 Nov 2024 20:50:00 +0000 Subject: [PATCH 01/11] Latest breakage flow --- DuckDuckGo.xcodeproj/project.pbxproj | 2 + .../xcshareddata/swiftpm/Package.resolved | 189 +++++++++++++++++- .../View/PrivacyDashboardViewController.swift | 3 +- 3 files changed, 184 insertions(+), 10 deletions(-) diff --git a/DuckDuckGo.xcodeproj/project.pbxproj b/DuckDuckGo.xcodeproj/project.pbxproj index 06a5ccb48f..7cabd720d5 100644 --- a/DuckDuckGo.xcodeproj/project.pbxproj +++ b/DuckDuckGo.xcodeproj/project.pbxproj @@ -4323,6 +4323,7 @@ 85F487B4276A8F2E003CE668 /* OnboardingTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OnboardingTests.swift; sourceTree = ""; }; 85F69B3B25EDE81F00978E59 /* URLExtensionTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = URLExtensionTests.swift; sourceTree = ""; }; 85F91D9327F47BC40096B1C8 /* History 5.xcdatamodel */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcdatamodel; path = "History 5.xcdatamodel"; sourceTree = ""; }; + 8DF602922CEBDD4A00B43AE0 /* privacy-dashboard */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = "privacy-dashboard"; path = "../privacy-dashboard"; sourceTree = SOURCE_ROOT; }; 9812D894276CEDA5004B6181 /* ContentBlockerRulesLists.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentBlockerRulesLists.swift; sourceTree = ""; }; 9826B09F2747DF3D0092F683 /* ContentBlocking.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentBlocking.swift; sourceTree = ""; }; 9826B0A12747DFEB0092F683 /* AppPrivacyConfigurationDataProvider.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppPrivacyConfigurationDataProvider.swift; sourceTree = ""; }; @@ -6034,6 +6035,7 @@ 3772BEDF2D01A1400019B9EF /* Utilities */, 3720B7F82D00DA4500D20F23 /* WebKitExtensions */, 7B76E6852AD5D77600186A84 /* XPCHelper */, + 8DF602922CEBDD4A00B43AE0 /* privacy-dashboard */, ); path = LocalPackages; sourceTree = ""; diff --git a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index fb5f5537b3..cfc2b8d2b6 100644 --- a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -1,12 +1,185 @@ { - "pins" : [ - { - "identity" : "apple-toolbox", - "kind" : "remoteSourceControl", - "location" : "https://github.com/duckduckgo/apple-toolbox.git", - "state" : { - "revision" : "0c13c5f056805f2d403618ccc3bfb833c303c68d", - "version" : "3.1.2" + "object": { + "pins": [ + { + "package": "AppleToolbox", + "repositoryURL": "https://github.com/duckduckgo/apple-toolbox.git", + "state": { + "branch": null, + "revision": "0c13c5f056805f2d403618ccc3bfb833c303c68d", + "version": "3.1.2" + } + }, + { + "package": "BareBonesBrowserKit", + "repositoryURL": "https://github.com/duckduckgo/BareBonesBrowser.git", + "state": { + "branch": null, + "revision": "31e5bfedc3c2ca005640c4bf2b6959d69b0e18b9", + "version": "0.1.0" + } + }, + { + "package": "BloomFilter", + "repositoryURL": "https://github.com/duckduckgo/bloom_cpp.git", + "state": { + "branch": null, + "revision": "8076199456290b61b4544bf2f4caf296759906a0", + "version": "3.0.0" + } + }, + { + "package": "BrowserServicesKit", + "repositoryURL": "https://github.com/duckduckgo/BrowserServicesKit", + "state": { + "branch": "mgurgel/new-breakage-form", + "revision": "bb0d926828f6978b3ff717ded8db34947efcd5a7", + "version": null + } + }, + { + "package": "ContentScopeScripts", + "repositoryURL": "https://github.com/duckduckgo/content-scope-scripts", + "state": { + "branch": null, + "revision": "32c3e2bce3cc20a079d96b3ee23a9cde5d2337c3", + "version": "6.35.0" + } + }, + { + "package": "Autofill", + "repositoryURL": "https://github.com/duckduckgo/duckduckgo-autofill.git", + "state": { + "branch": null, + "revision": "c992041d16ec10d790e6204dce9abf9966d1363c", + "version": "15.1.0" + } + }, + { + "package": "GRDB", + "repositoryURL": "https://github.com/duckduckgo/GRDB.swift.git", + "state": { + "branch": null, + "revision": "5b2f6a81099d26ae0f9e38788f51490cd6a4b202", + "version": "2.4.2" + } + }, + { + "package": "Gzip", + "repositoryURL": "https://github.com/1024jp/GzipSwift.git", + "state": { + "branch": null, + "revision": "731037f6cc2be2ec01562f6597c1d0aa3fe6fd05", + "version": "6.0.1" + } + }, + { + "package": "Lottie", + "repositoryURL": "https://github.com/airbnb/lottie-spm.git", + "state": { + "branch": null, + "revision": "1d29eccc24cc8b75bff9f6804155112c0ffc9605", + "version": "4.4.3" + } + }, + { + "package": "OHHTTPStubs", + "repositoryURL": "https://github.com/AliSoftware/OHHTTPStubs.git", + "state": { + "branch": null, + "revision": "12f19662426d0434d6c330c6974d53e2eb10ecd9", + "version": "9.1.0" + } + }, + { + "package": "OpenSSL", + "repositoryURL": "https://github.com/duckduckgo/OpenSSL-XCFramework", + "state": { + "branch": null, + "revision": "71d303cbfa150e1fac99ffc7b4f67aad9c7a5002", + "version": "3.1.5004" + } + }, + { + "package": "Punycode", + "repositoryURL": "https://github.com/gumob/PunycodeSwift.git", + "state": { + "branch": null, + "revision": "30a462bdb4398ea835a3585472229e0d74b36ba5", + "version": "3.0.0" + } + }, + { + "package": "Sparkle", + "repositoryURL": "https://github.com/sparkle-project/Sparkle.git", + "state": { + "branch": null, + "revision": "b456fd404954a9e13f55aa0c88cd5a40b8399638", + "version": "2.6.3" + } + }, + { + "package": "swift-argument-parser", + "repositoryURL": "https://github.com/apple/swift-argument-parser.git", + "state": { + "branch": null, + "revision": "0fbc8848e389af3bb55c182bc19ca9d5dc2f255b", + "version": "1.4.0" + } + }, + { + "package": "swift-snapshot-testing", + "repositoryURL": "https://github.com/pointfreeco/swift-snapshot-testing", + "state": { + "branch": null, + "revision": "5b0c434778f2c1a4c9b5ebdb8682b28e84dd69bd", + "version": "1.15.4" + } + }, + { + "package": "swift-syntax", + "repositoryURL": "https://github.com/apple/swift-syntax", + "state": { + "branch": null, + "revision": "64889f0c732f210a935a0ad7cda38f77f876262d", + "version": "509.1.1" + } + }, + { + "package": "Swifter", + "repositoryURL": "https://github.com/httpswift/swifter.git", + "state": { + "branch": null, + "revision": "9483a5d459b45c3ffd059f7b55f9638e268632fd", + "version": "1.5.0" + } + }, + { + "package": "DDGSyncCrypto", + "repositoryURL": "https://github.com/duckduckgo/sync_crypto", + "state": { + "branch": null, + "revision": "0c8bf3c0e75591bc366407b9d7a73a9fcfc7736f", + "version": "0.3.0" + } + }, + { + "package": "TrackerRadarKit", + "repositoryURL": "https://github.com/duckduckgo/TrackerRadarKit", + "state": { + "branch": null, + "revision": "5de0a610a7927b638a5fd463a53032c9934a2c3b", + "version": "3.0.0" + } + }, + { + "package": "WireGuardKit", + "repositoryURL": "https://github.com/duckduckgo/wireguard-apple", + "state": { + "branch": null, + "revision": "13fd026384b1af11048451061cc1b21434990668", + "version": "1.1.3" + } } }, { diff --git a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift index efeb045455..dd2b5360bd 100644 --- a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift +++ b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift @@ -34,7 +34,7 @@ final class PrivacyDashboardViewController: NSViewController { struct Constants { static let initialContentHeight: CGFloat = 489.0 - static let reportBrokenSiteInitialContentHeight = 587.0 + 28.0 + static let reportBrokenSiteInitialContentHeight = 587c.0 + 28.0 static let initialContentWidth: CGFloat = 360.0 } @@ -81,7 +81,6 @@ final class PrivacyDashboardViewController: NSViewController { let toggleReportingManager = ToggleReportingManager(feature: toggleReportingFeature) self.privacyDashboardController = PrivacyDashboardController(privacyInfo: privacyInfo, entryPoint: entryPoint, - variant: .control, toggleReportingManager: toggleReportingManager, eventMapping: eventMapping) super.init(nibName: nil, bundle: nil) From 9e16a91cdcadc3decd31a8b5a2765b8621239044 Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Wed, 20 Nov 2024 14:20:03 +0000 Subject: [PATCH 02/11] Loading feedback form from Privacy Dashboard --- .../View/PrivacyDashboardViewController.swift | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift index dd2b5360bd..49798e9f9b 100644 --- a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift +++ b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift @@ -250,7 +250,10 @@ extension PrivacyDashboardViewController: PrivacyDashboardControllerDelegate { } func privacyDashboardControllerDidRequestShowGeneralFeedback(_ privacyDashboardController: PrivacyDashboardController) { - // Not used in macOS + DispatchQueue.main.asyncAfter(deadline: .now() + 0.35) { + FeedbackPresenter.presentFeedbackForm() + } + dismiss() } func privacyDashboardController(_ privacyDashboardController: PrivacyDashboardController, From bcc6287c7761215cf22a22c9ec174ff4c4ac1241 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20=C5=81yp?= Date: Thu, 21 Nov 2024 15:20:09 +0100 Subject: [PATCH 03/11] Change branch to jacek's --- .../xcshareddata/swiftpm/Package.resolved | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index cfc2b8d2b6..3e9362ad3e 100644 --- a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -32,8 +32,8 @@ "package": "BrowserServicesKit", "repositoryURL": "https://github.com/duckduckgo/BrowserServicesKit", "state": { - "branch": "mgurgel/new-breakage-form", - "revision": "bb0d926828f6978b3ff717ded8db34947efcd5a7", + "branch": "jacek/new-breakage-form", + "revision": "d015603f35a80acf247ebc28e0161e23ccd3067d", "version": null } }, @@ -42,8 +42,8 @@ "repositoryURL": "https://github.com/duckduckgo/content-scope-scripts", "state": { "branch": null, - "revision": "32c3e2bce3cc20a079d96b3ee23a9cde5d2337c3", - "version": "6.35.0" + "revision": "6cab7bdb584653a5dc007cc1ae827ec41c5a91bc", + "version": "6.29.0" } }, { @@ -60,8 +60,8 @@ "repositoryURL": "https://github.com/duckduckgo/GRDB.swift.git", "state": { "branch": null, - "revision": "5b2f6a81099d26ae0f9e38788f51490cd6a4b202", - "version": "2.4.2" + "revision": "4225b85c9a0c50544e413a1ea1e502c802b44b35", + "version": "2.4.0" } }, { From 2df0ffb7e90aeef3e9d5e9d71a584c824494f2a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20=C5=81yp?= Date: Thu, 21 Nov 2024 16:52:33 +0100 Subject: [PATCH 04/11] Update to newest BSK changes --- .../xcshareddata/swiftpm/Package.resolved | 6 +++--- .../View/PrivacyDashboardViewController.swift | 19 +++---------------- 2 files changed, 6 insertions(+), 19 deletions(-) diff --git a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index 3e9362ad3e..3e545d6b6c 100644 --- a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -33,7 +33,7 @@ "repositoryURL": "https://github.com/duckduckgo/BrowserServicesKit", "state": { "branch": "jacek/new-breakage-form", - "revision": "d015603f35a80acf247ebc28e0161e23ccd3067d", + "revision": "f188fb3fb4f598bd67f4c0d209aa81fe8e762916", "version": null } }, @@ -60,8 +60,8 @@ "repositoryURL": "https://github.com/duckduckgo/GRDB.swift.git", "state": { "branch": null, - "revision": "4225b85c9a0c50544e413a1ea1e502c802b44b35", - "version": "2.4.0" + "revision": "5b2f6a81099d26ae0f9e38788f51490cd6a4b202", + "version": "2.4.2" } }, { diff --git a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift index 49798e9f9b..7bc48a3d2f 100644 --- a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift +++ b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift @@ -186,15 +186,6 @@ final class PrivacyDashboardViewController: NSViewController { extension PrivacyDashboardViewController: PrivacyDashboardControllerDelegate { - func privacyDashboardController(_ privacyDashboardController: PrivacyDashboardController, - didSelectBreakageCategory category: String) { - // Not used in macOS - } - - func privacyDashboardControllerDidRequestShowReportBrokenSite(_ privacyDashboardController: PrivacyDashboardController) { - // Not used in macOS: PixelKit.fire(GeneralPixel.privacyDashboardReportBrokenSite) - } - func privacyDashboardController(_ privacyDashboardController: PrivacyDashboardController, didChangeProtectionSwitch protectionState: ProtectionState, didSendReport: Bool) { @@ -245,14 +236,10 @@ extension PrivacyDashboardViewController: PrivacyDashboardControllerDelegate { dismiss() } - func privacyDashboardControllerDidRequestShowAlertForMissingDescription(_ privacyDashboardController: PrivacyDashboardController) { - // Not used in macOS - } - func privacyDashboardControllerDidRequestShowGeneralFeedback(_ privacyDashboardController: PrivacyDashboardController) { - DispatchQueue.main.asyncAfter(deadline: .now() + 0.35) { - FeedbackPresenter.presentFeedbackForm() - } +// DispatchQueue.main.asyncAfter(deadline: .now() + 0.35) { +// FeedbackPresenter.presentFeedbackForm() +// } dismiss() } From 678ed5c4ea851aa3732db253e48251608cd7e5fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20=C5=81yp?= Date: Thu, 21 Nov 2024 17:41:55 +0100 Subject: [PATCH 05/11] Fix wrong dashboard showing up --- DuckDuckGo.xcodeproj/project.pbxproj | 2 - .../xcshareddata/swiftpm/Package.resolved | 189 +----------------- .../View/PrivacyDashboardViewController.swift | 4 +- 3 files changed, 9 insertions(+), 186 deletions(-) diff --git a/DuckDuckGo.xcodeproj/project.pbxproj b/DuckDuckGo.xcodeproj/project.pbxproj index 7cabd720d5..06a5ccb48f 100644 --- a/DuckDuckGo.xcodeproj/project.pbxproj +++ b/DuckDuckGo.xcodeproj/project.pbxproj @@ -4323,7 +4323,6 @@ 85F487B4276A8F2E003CE668 /* OnboardingTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OnboardingTests.swift; sourceTree = ""; }; 85F69B3B25EDE81F00978E59 /* URLExtensionTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = URLExtensionTests.swift; sourceTree = ""; }; 85F91D9327F47BC40096B1C8 /* History 5.xcdatamodel */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcdatamodel; path = "History 5.xcdatamodel"; sourceTree = ""; }; - 8DF602922CEBDD4A00B43AE0 /* privacy-dashboard */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = "privacy-dashboard"; path = "../privacy-dashboard"; sourceTree = SOURCE_ROOT; }; 9812D894276CEDA5004B6181 /* ContentBlockerRulesLists.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentBlockerRulesLists.swift; sourceTree = ""; }; 9826B09F2747DF3D0092F683 /* ContentBlocking.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentBlocking.swift; sourceTree = ""; }; 9826B0A12747DFEB0092F683 /* AppPrivacyConfigurationDataProvider.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppPrivacyConfigurationDataProvider.swift; sourceTree = ""; }; @@ -6035,7 +6034,6 @@ 3772BEDF2D01A1400019B9EF /* Utilities */, 3720B7F82D00DA4500D20F23 /* WebKitExtensions */, 7B76E6852AD5D77600186A84 /* XPCHelper */, - 8DF602922CEBDD4A00B43AE0 /* privacy-dashboard */, ); path = LocalPackages; sourceTree = ""; diff --git a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index 3e545d6b6c..fb5f5537b3 100644 --- a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -1,185 +1,12 @@ { - "object": { - "pins": [ - { - "package": "AppleToolbox", - "repositoryURL": "https://github.com/duckduckgo/apple-toolbox.git", - "state": { - "branch": null, - "revision": "0c13c5f056805f2d403618ccc3bfb833c303c68d", - "version": "3.1.2" - } - }, - { - "package": "BareBonesBrowserKit", - "repositoryURL": "https://github.com/duckduckgo/BareBonesBrowser.git", - "state": { - "branch": null, - "revision": "31e5bfedc3c2ca005640c4bf2b6959d69b0e18b9", - "version": "0.1.0" - } - }, - { - "package": "BloomFilter", - "repositoryURL": "https://github.com/duckduckgo/bloom_cpp.git", - "state": { - "branch": null, - "revision": "8076199456290b61b4544bf2f4caf296759906a0", - "version": "3.0.0" - } - }, - { - "package": "BrowserServicesKit", - "repositoryURL": "https://github.com/duckduckgo/BrowserServicesKit", - "state": { - "branch": "jacek/new-breakage-form", - "revision": "f188fb3fb4f598bd67f4c0d209aa81fe8e762916", - "version": null - } - }, - { - "package": "ContentScopeScripts", - "repositoryURL": "https://github.com/duckduckgo/content-scope-scripts", - "state": { - "branch": null, - "revision": "6cab7bdb584653a5dc007cc1ae827ec41c5a91bc", - "version": "6.29.0" - } - }, - { - "package": "Autofill", - "repositoryURL": "https://github.com/duckduckgo/duckduckgo-autofill.git", - "state": { - "branch": null, - "revision": "c992041d16ec10d790e6204dce9abf9966d1363c", - "version": "15.1.0" - } - }, - { - "package": "GRDB", - "repositoryURL": "https://github.com/duckduckgo/GRDB.swift.git", - "state": { - "branch": null, - "revision": "5b2f6a81099d26ae0f9e38788f51490cd6a4b202", - "version": "2.4.2" - } - }, - { - "package": "Gzip", - "repositoryURL": "https://github.com/1024jp/GzipSwift.git", - "state": { - "branch": null, - "revision": "731037f6cc2be2ec01562f6597c1d0aa3fe6fd05", - "version": "6.0.1" - } - }, - { - "package": "Lottie", - "repositoryURL": "https://github.com/airbnb/lottie-spm.git", - "state": { - "branch": null, - "revision": "1d29eccc24cc8b75bff9f6804155112c0ffc9605", - "version": "4.4.3" - } - }, - { - "package": "OHHTTPStubs", - "repositoryURL": "https://github.com/AliSoftware/OHHTTPStubs.git", - "state": { - "branch": null, - "revision": "12f19662426d0434d6c330c6974d53e2eb10ecd9", - "version": "9.1.0" - } - }, - { - "package": "OpenSSL", - "repositoryURL": "https://github.com/duckduckgo/OpenSSL-XCFramework", - "state": { - "branch": null, - "revision": "71d303cbfa150e1fac99ffc7b4f67aad9c7a5002", - "version": "3.1.5004" - } - }, - { - "package": "Punycode", - "repositoryURL": "https://github.com/gumob/PunycodeSwift.git", - "state": { - "branch": null, - "revision": "30a462bdb4398ea835a3585472229e0d74b36ba5", - "version": "3.0.0" - } - }, - { - "package": "Sparkle", - "repositoryURL": "https://github.com/sparkle-project/Sparkle.git", - "state": { - "branch": null, - "revision": "b456fd404954a9e13f55aa0c88cd5a40b8399638", - "version": "2.6.3" - } - }, - { - "package": "swift-argument-parser", - "repositoryURL": "https://github.com/apple/swift-argument-parser.git", - "state": { - "branch": null, - "revision": "0fbc8848e389af3bb55c182bc19ca9d5dc2f255b", - "version": "1.4.0" - } - }, - { - "package": "swift-snapshot-testing", - "repositoryURL": "https://github.com/pointfreeco/swift-snapshot-testing", - "state": { - "branch": null, - "revision": "5b0c434778f2c1a4c9b5ebdb8682b28e84dd69bd", - "version": "1.15.4" - } - }, - { - "package": "swift-syntax", - "repositoryURL": "https://github.com/apple/swift-syntax", - "state": { - "branch": null, - "revision": "64889f0c732f210a935a0ad7cda38f77f876262d", - "version": "509.1.1" - } - }, - { - "package": "Swifter", - "repositoryURL": "https://github.com/httpswift/swifter.git", - "state": { - "branch": null, - "revision": "9483a5d459b45c3ffd059f7b55f9638e268632fd", - "version": "1.5.0" - } - }, - { - "package": "DDGSyncCrypto", - "repositoryURL": "https://github.com/duckduckgo/sync_crypto", - "state": { - "branch": null, - "revision": "0c8bf3c0e75591bc366407b9d7a73a9fcfc7736f", - "version": "0.3.0" - } - }, - { - "package": "TrackerRadarKit", - "repositoryURL": "https://github.com/duckduckgo/TrackerRadarKit", - "state": { - "branch": null, - "revision": "5de0a610a7927b638a5fd463a53032c9934a2c3b", - "version": "3.0.0" - } - }, - { - "package": "WireGuardKit", - "repositoryURL": "https://github.com/duckduckgo/wireguard-apple", - "state": { - "branch": null, - "revision": "13fd026384b1af11048451061cc1b21434990668", - "version": "1.1.3" - } + "pins" : [ + { + "identity" : "apple-toolbox", + "kind" : "remoteSourceControl", + "location" : "https://github.com/duckduckgo/apple-toolbox.git", + "state" : { + "revision" : "0c13c5f056805f2d403618ccc3bfb833c303c68d", + "version" : "3.1.2" } }, { diff --git a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift index 7bc48a3d2f..14c09325b2 100644 --- a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift +++ b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift @@ -237,10 +237,8 @@ extension PrivacyDashboardViewController: PrivacyDashboardControllerDelegate { } func privacyDashboardControllerDidRequestShowGeneralFeedback(_ privacyDashboardController: PrivacyDashboardController) { -// DispatchQueue.main.asyncAfter(deadline: .now() + 0.35) { -// FeedbackPresenter.presentFeedbackForm() -// } dismiss() + FeedbackPresenter.presentFeedbackForm() } func privacyDashboardController(_ privacyDashboardController: PrivacyDashboardController, From 87566c31fbc93d717d09cbc41bb39b1eb877cc38 Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Fri, 13 Dec 2024 13:52:34 +0000 Subject: [PATCH 06/11] Updated initial height of dashboard window --- .../PrivacyDashboard/View/PrivacyDashboardViewController.swift | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift index 14c09325b2..aff006d5ec 100644 --- a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift +++ b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift @@ -34,7 +34,7 @@ final class PrivacyDashboardViewController: NSViewController { struct Constants { static let initialContentHeight: CGFloat = 489.0 - static let reportBrokenSiteInitialContentHeight = 587c.0 + 28.0 + static let reportBrokenSiteInitialContentHeight = 372.0 + 28.0 static let initialContentWidth: CGFloat = 360.0 } @@ -127,6 +127,7 @@ final class PrivacyDashboardViewController: NSViewController { configuration.preferences.setValue(true, forKey: "developerExtrasEnabled") #endif let webView = PrivacyDashboardWebView(frame: .zero, configuration: configuration) + self.webView = webView view.addAndLayout(webView) From 20f219edb2192f84f1e392935d4c45dfb4e634ab Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Tue, 17 Dec 2024 15:54:08 +0000 Subject: [PATCH 07/11] Disable animation on brekage report window --- DuckDuckGo/Menus/MainMenuActions.swift | 2 +- .../View/PrivacyDashboardViewController.swift | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/DuckDuckGo/Menus/MainMenuActions.swift b/DuckDuckGo/Menus/MainMenuActions.swift index 77e928f30b..33d5bf67d0 100644 --- a/DuckDuckGo/Menus/MainMenuActions.swift +++ b/DuckDuckGo/Menus/MainMenuActions.swift @@ -1241,7 +1241,7 @@ extension MainViewController: FindInPageDelegate { extension AppDelegate: PrivacyDashboardViewControllerSizeDelegate { func privacyDashboardViewControllerDidChange(size: NSSize) { - privacyDashboardWindow?.setFrame(NSRect(origin: .zero, size: size), display: true, animate: true) + privacyDashboardWindow?.setFrame(NSRect(origin: .zero, size: size), display: true, animate: false) } } diff --git a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift index aff006d5ec..c53e89b306 100644 --- a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift +++ b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift @@ -34,7 +34,7 @@ final class PrivacyDashboardViewController: NSViewController { struct Constants { static let initialContentHeight: CGFloat = 489.0 - static let reportBrokenSiteInitialContentHeight = 372.0 + 28.0 + static let reportBrokenSiteInitialContentHeight = 406.0 + 28.0 static let initialContentWidth: CGFloat = 360.0 } @@ -102,7 +102,7 @@ final class PrivacyDashboardViewController: NSViewController { } override func loadView() { - view = NSView(frame: NSRect(x: 0, y: 0, width: 360, height: 489)) + view = ColorView(frame: NSRect(x: 0, y: 0, width: 360, height: 489), backgroundColor: NSColor(named: "PopoverBackgroundColor")) initWebView() } @@ -127,7 +127,7 @@ final class PrivacyDashboardViewController: NSViewController { configuration.preferences.setValue(true, forKey: "developerExtrasEnabled") #endif let webView = PrivacyDashboardWebView(frame: .zero, configuration: configuration) - + webView.setValue(false, forKey: "drawsBackground") self.webView = webView view.addAndLayout(webView) From 906ffd44d82aa8ea757a8bc20fb4aad04a04ed22 Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Thu, 9 Jan 2025 13:11:33 +0000 Subject: [PATCH 08/11] Privacy Dashboard 8.0.0 --- DuckDuckGo.xcodeproj/project.pbxproj | 4 ++-- .../xcshareddata/swiftpm/Package.resolved | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/DuckDuckGo.xcodeproj/project.pbxproj b/DuckDuckGo.xcodeproj/project.pbxproj index 06a5ccb48f..dde5854ab3 100644 --- a/DuckDuckGo.xcodeproj/project.pbxproj +++ b/DuckDuckGo.xcodeproj/project.pbxproj @@ -15385,8 +15385,8 @@ isa = XCRemoteSwiftPackageReference; repositoryURL = "https://github.com/duckduckgo/BrowserServicesKit"; requirement = { - kind = exactVersion; - version = 225.0.0; + branch = "mgurgel/improved-breakage-form"; + kind = branch; }; }; 9FF521422BAA8FF300B9819B /* XCRemoteSwiftPackageReference "lottie-spm" */ = { diff --git a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index fb5f5537b3..f21d7e8d48 100644 --- a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -32,8 +32,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/duckduckgo/BrowserServicesKit", "state" : { - "revision" : "20e6eaf0b1e423d9a270e2d460cae284c08f73d8", - "version" : "225.0.0" + "branch" : "mgurgel/improved-breakage-form", + "revision" : "82a612a0c2d164a797f148356dd8d51dd804c52c" } }, { @@ -104,8 +104,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/duckduckgo/privacy-dashboard", "state" : { - "revision" : "bea4d750913ef82c10cd06e791686501c8e648e4", - "version" : "7.6.0" + "revision" : "3f58e008d4e9d1b56ab12dbb95bd891045cf2758", + "version" : "8.0.0" } }, { From f3f71a5ef1e2918803e82eef49c574e0a41beded Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Tue, 14 Jan 2025 13:41:52 +0000 Subject: [PATCH 09/11] BSK update --- LocalPackages/FeatureFlags/Package.swift | 2 +- LocalPackages/NetworkProtectionMac/Package.swift | 2 +- LocalPackages/NewTabPage/Package.swift | 2 +- LocalPackages/SubscriptionUI/Package.swift | 2 +- LocalPackages/WebKitExtensions/Package.swift | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/LocalPackages/FeatureFlags/Package.swift b/LocalPackages/FeatureFlags/Package.swift index 960f4c7a76..d596fa8366 100644 --- a/LocalPackages/FeatureFlags/Package.swift +++ b/LocalPackages/FeatureFlags/Package.swift @@ -32,7 +32,7 @@ let package = Package( targets: ["FeatureFlags"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", exact: "225.0.0"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), ], targets: [ // Targets are the basic building blocks of a package, defining a module or a test suite. diff --git a/LocalPackages/NetworkProtectionMac/Package.swift b/LocalPackages/NetworkProtectionMac/Package.swift index ef83a3965f..898c687dff 100644 --- a/LocalPackages/NetworkProtectionMac/Package.swift +++ b/LocalPackages/NetworkProtectionMac/Package.swift @@ -33,7 +33,7 @@ let package = Package( .library(name: "VPNAppLauncher", targets: ["VPNAppLauncher"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", exact: "225.0.0"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), .package(url: "https://github.com/airbnb/lottie-spm", exact: "4.4.3"), .package(path: "../AppLauncher"), .package(path: "../UDSHelper"), diff --git a/LocalPackages/NewTabPage/Package.swift b/LocalPackages/NewTabPage/Package.swift index 68a041c2a5..31f352720c 100644 --- a/LocalPackages/NewTabPage/Package.swift +++ b/LocalPackages/NewTabPage/Package.swift @@ -32,7 +32,7 @@ let package = Package( targets: ["NewTabPage"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", exact: "225.0.0"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), .package(path: "../WebKitExtensions"), .package(path: "../Utilities"), ], diff --git a/LocalPackages/SubscriptionUI/Package.swift b/LocalPackages/SubscriptionUI/Package.swift index 0848795ec1..55e8263f83 100644 --- a/LocalPackages/SubscriptionUI/Package.swift +++ b/LocalPackages/SubscriptionUI/Package.swift @@ -13,7 +13,7 @@ let package = Package( targets: ["SubscriptionUI"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", exact: "225.0.0"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), .package(path: "../SwiftUIExtensions"), .package(path: "../FeatureFlags") ], diff --git a/LocalPackages/WebKitExtensions/Package.swift b/LocalPackages/WebKitExtensions/Package.swift index 38502ce36a..b78e032b67 100644 --- a/LocalPackages/WebKitExtensions/Package.swift +++ b/LocalPackages/WebKitExtensions/Package.swift @@ -32,7 +32,7 @@ let package = Package( ), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", exact: "225.0.0"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), .package(path: "../AppKitExtensions") ], targets: [ From 7ea9a8f7ef57ef09f8dcef1c6c2607fe953af0f1 Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Tue, 14 Jan 2025 14:47:12 +0000 Subject: [PATCH 10/11] BSK update --- LocalPackages/DataBrokerProtection/Package.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LocalPackages/DataBrokerProtection/Package.swift b/LocalPackages/DataBrokerProtection/Package.swift index bdb4a5fec8..a70d65e74c 100644 --- a/LocalPackages/DataBrokerProtection/Package.swift +++ b/LocalPackages/DataBrokerProtection/Package.swift @@ -29,7 +29,7 @@ let package = Package( targets: ["DataBrokerProtection"]) ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", exact: "225.0.0"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), .package(path: "../SwiftUIExtensions"), .package(path: "../AppKitExtensions"), .package(path: "../XPCHelper"), From ca102aca2dccaa2919d74b7d8a2a72fc2b8c2117 Mon Sep 17 00:00:00 2001 From: Marcos Gurgel Date: Fri, 17 Jan 2025 17:54:44 +0000 Subject: [PATCH 11/11] Aligning Privacy Dashboard EventMapping with iOS (#3744) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Task/Issue URL: https://app.asana.com/0/1206594217596623/1209173355503842/f **Description**: Set ups Privacy Dashboard EventMapping as to align with iOS. Each mapped event fires a pixel when invoked by the Privacy Dashboard. See https://github.com/duckduckgo/BrowserServicesKit/pull/1167 Note: not all events are currently used by the Dashboard. Some are being deprecated, which is why they might not be fired at all even though they still exist in the mapping. **Steps to test this PR**: 1. Invoke the breakage form in the two possible ways: Open the Privacy Dashboard and click on "Report a problem with this site" Open the app menu ••• and click on "Report Broken Site” (iOS) 2. Confirm that the pixel `m_report-broken-site_shown` was fired 3. Submit a report 4. Confirm that the pixels `epbf_macos_desktop` and `m_report-broken-site_sent` were fired --- DuckDuckGo.xcodeproj/project.pbxproj | 2 +- .../xcshareddata/swiftpm/Package.resolved | 16 ++++++++-------- .../View/PrivacyDashboardViewController.swift | 18 +++++++++++++++--- DuckDuckGo/Statistics/NonStandardPixel.swift | 6 ++++++ .../DataBrokerProtection/Package.swift | 2 +- LocalPackages/FeatureFlags/Package.swift | 2 +- .../NetworkProtectionMac/Package.swift | 2 +- LocalPackages/NewTabPage/Package.swift | 2 +- LocalPackages/SubscriptionUI/Package.swift | 2 +- LocalPackages/WebKitExtensions/Package.swift | 2 +- .../WebsiteBreakageReportTests.swift | 16 ++++++++++++++++ 11 files changed, 52 insertions(+), 18 deletions(-) diff --git a/DuckDuckGo.xcodeproj/project.pbxproj b/DuckDuckGo.xcodeproj/project.pbxproj index dde5854ab3..9201b39429 100644 --- a/DuckDuckGo.xcodeproj/project.pbxproj +++ b/DuckDuckGo.xcodeproj/project.pbxproj @@ -15385,7 +15385,7 @@ isa = XCRemoteSwiftPackageReference; repositoryURL = "https://github.com/duckduckgo/BrowserServicesKit"; requirement = { - branch = "mgurgel/improved-breakage-form"; + branch = "mgurgel/improved-breakage-form-pixel"; kind = branch; }; }; diff --git a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index f21d7e8d48..dfcae91ded 100644 --- a/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -32,8 +32,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/duckduckgo/BrowserServicesKit", "state" : { - "branch" : "mgurgel/improved-breakage-form", - "revision" : "82a612a0c2d164a797f148356dd8d51dd804c52c" + "branch" : "mgurgel/improved-breakage-form-pixel", + "revision" : "f85a4199ba4251921ecff6d110527c8d5c44e329" } }, { @@ -41,8 +41,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/duckduckgo/content-scope-scripts", "state" : { - "revision" : "7958ddab724c26326333cae13fe81478290607fa", - "version" : "7.6.0" + "revision" : "0502ed7de4130bd8705daebaca9aeb20d3e62d15", + "version" : "7.5.0" } }, { @@ -104,8 +104,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/duckduckgo/privacy-dashboard", "state" : { - "revision" : "3f58e008d4e9d1b56ab12dbb95bd891045cf2758", - "version" : "8.0.0" + "branch" : "pr-releases/pr-302", + "revision" : "05d04de7505117b32949b2007e5a56ba2d39469b" } }, { @@ -167,8 +167,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/duckduckgo/sync_crypto", "state" : { - "revision" : "cc726cebb67367466bc31ced4784e16d44ac68d1", - "version" : "0.4.0" + "revision" : "0c8bf3c0e75591bc366407b9d7a73a9fcfc7736f", + "version" : "0.3.0" } }, { diff --git a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift index c53e89b306..04a6aa222d 100644 --- a/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift +++ b/DuckDuckGo/PrivacyDashboard/View/PrivacyDashboardViewController.swift @@ -62,8 +62,6 @@ final class PrivacyDashboardViewController: NSViewController { }, keyValueStoring: UserDefaults.standard) }() - private let eventMapping = EventMapping { _, _, _, _ in } - private let permissionHandler = PrivacyDashboardPermissionHandler() private var preferredMaxHeight: CGFloat = Constants.initialContentHeight func setPreferredMaxHeight(_ height: CGFloat) { @@ -73,6 +71,20 @@ final class PrivacyDashboardViewController: NSViewController { var sizeDelegate: PrivacyDashboardViewControllerSizeDelegate? private weak var tabViewModel: TabViewModel? + private let privacyDashboardEvents = EventMapping { event, _, parameters, _ in + let domainEvent: NonStandardPixel + switch event { + case .showReportBrokenSite: domainEvent = .brokenSiteReportShown + case .reportBrokenSiteShown: domainEvent = .brokenSiteReportShown + case .reportBrokenSiteSent: domainEvent = .brokenSiteReportSent + } + if let parameters { + PixelKit.fire(NonStandardEvent(domainEvent), withAdditionalParameters: parameters) + } else { + PixelKit.fire(NonStandardEvent(domainEvent)) + } + } + init(privacyInfo: PrivacyInfo? = nil, entryPoint: PrivacyDashboardEntryPoint = .dashboard, privacyConfigurationManager: PrivacyConfigurationManaging = ContentBlocking.shared.privacyConfigurationManager) { @@ -82,7 +94,7 @@ final class PrivacyDashboardViewController: NSViewController { self.privacyDashboardController = PrivacyDashboardController(privacyInfo: privacyInfo, entryPoint: entryPoint, toggleReportingManager: toggleReportingManager, - eventMapping: eventMapping) + eventMapping: privacyDashboardEvents) super.init(nibName: nil, bundle: nil) } diff --git a/DuckDuckGo/Statistics/NonStandardPixel.swift b/DuckDuckGo/Statistics/NonStandardPixel.swift index b528aef0a1..5accaf5020 100644 --- a/DuckDuckGo/Statistics/NonStandardPixel.swift +++ b/DuckDuckGo/Statistics/NonStandardPixel.swift @@ -26,6 +26,9 @@ import Configuration enum NonStandardPixel: PixelKitEventV2 { case brokenSiteReport + case brokenSiteReportShown + case brokenSiteReportSent + case privacyDashboardReportBrokenSite case emailEnabled case emailDisabled case emailUserPressedUseAddress @@ -35,6 +38,9 @@ enum NonStandardPixel: PixelKitEventV2 { var name: String { switch self { case .brokenSiteReport: return "epbf_macos_desktop" + case .brokenSiteReportSent: return "m_report-broken-site_sent" + case .brokenSiteReportShown: return "m_report-broken-site_shown" + case .privacyDashboardReportBrokenSite: return "mp_rb" case .emailEnabled: return "email_enabled_macos_desktop" case .emailDisabled: return "email_disabled_macos_desktop" case .emailUserPressedUseAddress: return "email_filled_main_macos_desktop" diff --git a/LocalPackages/DataBrokerProtection/Package.swift b/LocalPackages/DataBrokerProtection/Package.swift index a70d65e74c..21a83f3f74 100644 --- a/LocalPackages/DataBrokerProtection/Package.swift +++ b/LocalPackages/DataBrokerProtection/Package.swift @@ -29,7 +29,7 @@ let package = Package( targets: ["DataBrokerProtection"]) ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form-pixel"), .package(path: "../SwiftUIExtensions"), .package(path: "../AppKitExtensions"), .package(path: "../XPCHelper"), diff --git a/LocalPackages/FeatureFlags/Package.swift b/LocalPackages/FeatureFlags/Package.swift index d596fa8366..ce06b688ee 100644 --- a/LocalPackages/FeatureFlags/Package.swift +++ b/LocalPackages/FeatureFlags/Package.swift @@ -32,7 +32,7 @@ let package = Package( targets: ["FeatureFlags"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form-pixel"), ], targets: [ // Targets are the basic building blocks of a package, defining a module or a test suite. diff --git a/LocalPackages/NetworkProtectionMac/Package.swift b/LocalPackages/NetworkProtectionMac/Package.swift index 898c687dff..4e09a12031 100644 --- a/LocalPackages/NetworkProtectionMac/Package.swift +++ b/LocalPackages/NetworkProtectionMac/Package.swift @@ -33,7 +33,7 @@ let package = Package( .library(name: "VPNAppLauncher", targets: ["VPNAppLauncher"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form-pixel"), .package(url: "https://github.com/airbnb/lottie-spm", exact: "4.4.3"), .package(path: "../AppLauncher"), .package(path: "../UDSHelper"), diff --git a/LocalPackages/NewTabPage/Package.swift b/LocalPackages/NewTabPage/Package.swift index 31f352720c..1920a18ab6 100644 --- a/LocalPackages/NewTabPage/Package.swift +++ b/LocalPackages/NewTabPage/Package.swift @@ -32,7 +32,7 @@ let package = Package( targets: ["NewTabPage"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form-pixel"), .package(path: "../WebKitExtensions"), .package(path: "../Utilities"), ], diff --git a/LocalPackages/SubscriptionUI/Package.swift b/LocalPackages/SubscriptionUI/Package.swift index 55e8263f83..73f197f815 100644 --- a/LocalPackages/SubscriptionUI/Package.swift +++ b/LocalPackages/SubscriptionUI/Package.swift @@ -13,7 +13,7 @@ let package = Package( targets: ["SubscriptionUI"]), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form-pixel"), .package(path: "../SwiftUIExtensions"), .package(path: "../FeatureFlags") ], diff --git a/LocalPackages/WebKitExtensions/Package.swift b/LocalPackages/WebKitExtensions/Package.swift index b78e032b67..f3c600a4a9 100644 --- a/LocalPackages/WebKitExtensions/Package.swift +++ b/LocalPackages/WebKitExtensions/Package.swift @@ -32,7 +32,7 @@ let package = Package( ), ], dependencies: [ - .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form"), + .package(url: "https://github.com/duckduckgo/BrowserServicesKit", branch: "mgurgel/improved-breakage-form-pixel"), .package(path: "../AppKitExtensions") ], targets: [ diff --git a/UnitTests/WebsiteBreakageReport/WebsiteBreakageReportTests.swift b/UnitTests/WebsiteBreakageReport/WebsiteBreakageReportTests.swift index cb7f619b4b..7d50333d95 100644 --- a/UnitTests/WebsiteBreakageReport/WebsiteBreakageReportTests.swift +++ b/UnitTests/WebsiteBreakageReport/WebsiteBreakageReportTests.swift @@ -33,6 +33,22 @@ class WebsiteBreakageReportTests: XCTestCase { line: #line) } + func testReportBrokenSiteShownPixel() { + fire(NonStandardEvent(NonStandardPixel.brokenSiteReportShown), + frequency: .standard, + and: .expect(pixelName: "m_report-broken-site_shown"), + file: #filePath, + line: #line) + } + + func testReportBrokenSiteSentPixel() { + fire(NonStandardEvent(NonStandardPixel.brokenSiteReportSent), + frequency: .standard, + and: .expect(pixelName: "m_report-broken-site_sent"), + file: #filePath, + line: #line) + } + func testCommonSetOfFields() throws { let breakage = BrokenSiteReport( siteUrl: URL(string: "https://example.test/")!,