chromium/chrome/browser/resources/app_home/BUILD.gn

# Copyright 2022 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_win || is_mac || is_linux)

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

  static_files = [ "app_home.html" ]

  non_web_component_files = [
    "app_home_empty_page.html.ts",
    "app_home_empty_page.ts",
    "app_home_utils.ts",
    "app_item.html.ts",
    "app_item.ts",
    "app_list.html.ts",
    "app_list.ts",
    "browser_proxy.ts",
    "deprecated_apps_link.html.ts",
    "deprecated_apps_link.ts",
  ]

  css_files = [
    "app_home_empty_page.css",
    "app_item.css",
    "app_list.css",
    "deprecated_apps_link.css",
  ]

  mojo_files_deps = [
    "//chrome/browser/ui/webui/app_home:mojo_bindings_ts__generator",
    "//chrome/browser/web_applications/mojom:mojom_web_apps_enum_ts__generator",
  ]

  mojo_files = [
    "$root_gen_dir/chrome/browser/web_applications/mojom/user_display_mode.mojom-webui.ts",
    "$root_gen_dir/chrome/browser/ui/webui/app_home/app_home.mojom-webui.ts",
  ]

  ts_composite = true
  ts_deps = [
    "//third_party/lit/v3_0:build_ts",
    "//ui/webui/resources/cr_elements:build_ts",
    "//ui/webui/resources/js:build_ts",
    "//ui/webui/resources/mojo:build_ts",
  ]
  ts_definitions = [ "//tools/typescript/definitions/metrics_private.d.ts" ]
  webui_context_type = "trusted"
}