chromium/ios/chrome/browser/price_insights/ui/BUILD.gn

# Copyright 2024 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//build/config/apple/swift_source_set.gni")

source_set("price_insights_ui") {
  sources = [
    "price_insights_cell.h",
    "price_insights_cell.mm",
    "price_insights_constants.h",
    "price_insights_constants.mm",
    "price_insights_item.h",
    "price_insights_item.mm",
    "price_insights_mutator.h",
  ]

  deps = [
    ":price_history_swift",
    "//base",
    "//components/strings",
    "//ios/chrome/browser/contextual_panel/ui:public",
    "//ios/chrome/browser/shared/ui/symbols",
    "//ios/chrome/browser/shared/ui/util",
    "//ios/chrome/browser/ui/price_notifications/cells",
    "//ios/chrome/common/ui/colors",
    "//ios/chrome/common/ui/util",
    "//ui/base",
    "//url",
  ]

  frameworks = [ "UIKit.framework" ]
}

source_set("unit_tests") {
  testonly = true
  sources = [ "price_insights_cell_unittest.mm" ]
  frameworks = [ "Foundation.framework" ]
  deps = [
    ":price_insights_ui",
    "//base",
    "//base/test:test_support",
    "//components/strings",
    "//ui/base",
    "//url",
  ]
}

swift_source_set("price_history_swift") {
  bridge_header = "price_history_swift_bridge.h"
  sources = [
    "price_history.swift",
    "price_history_provider.swift",
  ]
  deps = [
    "//ios/chrome/browser/price_insights/ui/resources",
    "//ios/chrome/browser/shared/public/metrics:metrics_bridge",
    "//ios/chrome/common/ui/colors",
  ]
  frameworks = [
    "Charts.framework",
    "Foundation.framework",
    "SwiftUI.framework",
    "UIKit.framework",
  ]
}