#include "chrome/browser/ui/views/payments/secure_payment_confirmation_views_util.h"
#include "base/feature_list.h"
#include "base/strings/strcat.h"
#include "build/build_config.h"
#include "chrome/app/vector_icons/vector_icons.h"
#include "chrome/browser/ui/views/accessibility/non_accessible_image_view.h"
#include "chrome/browser/ui/views/chrome_layout_provider.h"
#include "chrome/browser/ui/views/chrome_typography.h"
#include "chrome/grit/theme_resources.h"
#include "components/payments/core/features.h"
#include "components/payments/core/sizes.h"
#include "ui/base/metadata/metadata_header_macros.h"
#include "ui/base/metadata/metadata_impl_macros.h"
#include "ui/compositor/layer.h"
#include "ui/gfx/paint_vector_icon.h"
#include "ui/native_theme/native_theme.h"
#include "ui/views/border.h"
#include "ui/views/controls/image_view.h"
#include "ui/views/controls/label.h"
#include "ui/views/controls/separator.h"
#include "ui/views/controls/styled_label.h"
#include "ui/views/layout/box_layout_view.h"
#include "ui/views/view.h"
#include "ui/views/view_class_properties.h"
namespace payments {
SecurePaymentConfirmationNetworkAndIssuerIconsTreatment;
namespace {
const gfx::VectorIcon& GetPlatformVectorIcon(bool dark_mode) { … }
int GetSecurePaymentConfirmationHeaderWidth() { … }
ui::ImageModel GetHeaderImageSkia(bool dark_mode) { … }
class SecurePaymentConfirmationHeaderIconView : public NonAccessibleImageView { … };
BEGIN_METADATA(…)
std::unique_ptr<views::View> CreateInlineHeaderIconView(
const SkBitmap& icon_bitmap,
int view_id) { … }
}
std::unique_ptr<views::View> CreateSecurePaymentConfirmationHeaderIcon(
int header_icon_id,
bool use_cart_image) { … }
std::unique_ptr<views::View>
CreateSecurePaymentConfirmationInlineImageTitleView(
std::unique_ptr<views::Label> title_text,
const SkBitmap& network_icon,
int network_icon_id,
const SkBitmap& issuer_icon,
int issuer_icon_id) { … }
std::unique_ptr<views::Label> CreateSecurePaymentConfirmationTitleLabel(
const std::u16string& title) { … }
std::unique_ptr<views::ImageView> CreateSecurePaymentConfirmationIconView(
const gfx::ImageSkia& image) { … }
std::u16string FormatMerchantLabel(
const std::optional<std::u16string>& merchant_name,
const std::optional<std::u16string>& merchant_origin) { … }
std::unique_ptr<views::StyledLabel> CreateSecurePaymentConfirmationOptOutView(
const std::u16string& relying_party_id,
const std::u16string& opt_out_label,
const std::u16string& opt_out_link_label,
base::RepeatingClosure on_click) { … }
}