blob: 145a0c4ebb3919f42e7f405a8c9d37b16b93040f [file] [log] [blame]
# Copyright 2023 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//ios/web/public/js_messaging/optimize_ts.gni")
source_set("web_selection") {
sources = [
"web_selection_java_script_feature.h",
"web_selection_java_script_feature.mm",
"web_selection_java_script_feature_observer.h",
"web_selection_response.h",
"web_selection_response.mm",
"web_selection_tab_helper.h",
"web_selection_tab_helper.mm",
]
deps = [
":web_selection_js",
"//components/shared_highlighting/ios",
"//ios/web/js_messaging:scoped_wk_script_message_handler",
"//ios/web/public",
"//ios/web/public/js_messaging",
]
configs += [ "//build/config/compiler:enable_arc" ]
}
source_set("unit_tests") {
configs += [ "//build/config/compiler:enable_arc" ]
testonly = true
sources = [
"web_selection_java_script_feature_unittest.mm",
"web_selection_tab_helper_unittest.mm",
]
deps = [
":web_selection",
"//base/test:test_support",
"//ios/chrome/browser/shared/model/browser_state:test_support",
"//ios/chrome/browser/shared/public/features",
"//ios/chrome/browser/web:web_internal",
"//ios/web/public/test",
"//testing/gtest",
]
}
optimize_ts("web_selection_js") {
visibility = [ ":web_selection" ]
sources = [ "resources/web_selection.ts" ]
deps = [
"//ios/web/public/js_messaging:gcrweb",
"//ios/web/public/js_messaging:util_scripts",
]
}