chromium/ash/webui/common/resources/cellular_setup/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("//ui/webui/resources/tools/build_webui.gni")

assert(is_chromeos_ash)

build_webui("build") {
  grd_prefix = "ash_common_cellular_setup"

  static_files = [
    "default_esim_profile_dark.svg",
    "default_esim_profile.svg",
    "error_dark.svg",
    "error.svg",
    "final_page_success_dark.svg",
    "final_page_success.svg",
    "sim_detect_error_dark.svg",
    "sim_detect_error.svg",
    "spinner.json",
  ]

  web_component_files = [
    "activation_code_page.ts",
    "activation_verification_page.ts",
    "base_page.ts",
    "button_bar.ts",
    "cellular_setup.ts",
    "confirmation_code_page.ts",
    "esim_flow_ui.ts",
    "final_page.ts",
    "profile_discovery_consent_page.ts",
    "profile_discovery_list_item.ts",
    "profile_discovery_list_page.ts",
    "provisioning_page.ts",
    "psim_flow_ui.ts",
    "setup_loading_page.ts",
  ]
  non_web_component_files = [
    "cellular_setup_delegate.ts",
    "cellular_types.ts",
    "esim_manager_listener_mixin.ts",
    "esim_manager_utils.ts",
    "mojo_interface_provider.ts",
    "subflow_mixin.ts",
    "webview_post_util.ts",
  ]

  icons_html_files = [ "cellular_setup_icons.html" ]

  ts_tsconfig_base = "tsconfig_base.json"

  ts_out_dir =
      "$root_gen_dir/ash/webui/common/resources/preprocessed/cellular_setup"
  ts_composite = true
  ts_definitions = [
    "//tools/typescript/definitions/context_menus.d.ts",
    "//tools/typescript/definitions/chrome_event.d.ts",
    "//tools/typescript/definitions/extension_types.d.ts",
    "//tools/typescript/definitions/metrics_private.d.ts",
    "//tools/typescript/definitions/pending.d.ts",
    "//tools/typescript/definitions/tabs.d.ts",
    "//tools/typescript/definitions/web_request.d.ts",
    "//tools/typescript/definitions/webview_tag.d.ts",
  ]
  ts_deps = [
    "//ash/webui/common/resources:build_ts",
    "//ash/webui/common/resources/cr_elements:build_ts",
    "//third_party/polymer/v3_0:library",
    "//ui/webui/resources/js:build_ts",
    "//ui/webui/resources/mojo:build_ts",
  ]

  webui_context_type = "relative"
  generate_grdp = true
  grd_resource_path_prefix = "ash/common/cellular_setup"
}