chromium/chrome/browser/resources/pdf/elements/viewer_thumbnail.css

/* 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. */

/* #css_wrapper_metadata_start
 * #type=style-lit
 * #import=chrome://resources/cr_elements/cr_shared_vars.css.js
 * #import=./pdf_shared.css.js
 * #include=pdf-shared
 * #css_wrapper_metadata_end */

:host {
  --focus-border-color: var(--google-blue-300);
  display: block;
}

:host(:focus) {
  outline: none;
}

#thumbnail {
  align-items: center;
  cursor: pointer;
  display: inline-flex;
  height: 140px;
  justify-content: center;
  margin-bottom: 12px;
  margin-inline-end: auto;
  margin-inline-start: auto;
  width: 108px;
}

:host([is-active]) #thumbnail {
  --active-background-color: white;
  background-color: var(--active-background-color);
  box-shadow: 0 0 0 6px var(--focus-border-color);
}

:host(:focus-visible) #thumbnail {
  box-shadow: 0 0 0 2px var(--focus-border-color);
}

:host([is-active]:focus-visible) #thumbnail {
  box-shadow: 0 0 0 8px var(--focus-border-color);
}

canvas {
  display: block;
  opacity: 0.5;
}

:host([is-active]) canvas {
  opacity: 1;
}

:host([is-active]) canvas:hover,
canvas:hover {
  opacity: 0.7;
}

#pageNumber {
  line-height: 1;
}