summaryrefslogtreecommitdiffstats
path: root/chromium/chrome/browser/resources/pdf/elements/viewer-page-indicator.html
blob: 70ad25786851138030b413e18b777c42c41bc6a4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<link rel="import" href="chrome://resources/html/assert.html">
<link rel="import" href="chrome://resources/html/polymer.html">
<link rel="import" href="chrome://resources/html/util.html">

<dom-module id="viewer-page-indicator">
  <template>
    <style>
      :host {
        display: flex;
        opacity: 0;
        pointer-events: none;
        position: fixed;
        right: 0;
        transition: opacity 400ms ease-in-out;
      }

      :host-context([dir=rtl]) {
        left: 0;
        right: auto;
      }

      #text {
        background-color: rgba(0, 0, 0, 0.5);
        border-radius: 5px;
        color: white;
        font-family: sans-serif;
        font-size: 12px;
        font-weight: bold;
        line-height: 48px;
        text-align: center;
        text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.8);
        width: 62px;
      }

      #triangle-end {
        border-bottom: 6px solid transparent;
        border-inline-start: 8px solid rgba(0, 0, 0, 0.5);
        border-top: 6px solid transparent;
        height: 0;
        margin-top: 18px;
        width: 0;
      }
    </style>
    <div id="text">{{label}}</div>
    <div id="triangle-end"></div>
  </template>
  <script src="viewer-page-indicator.js"></script>
</dom-module>